#321
PartitiiNumar1
Se dă un număr natural n
. Determinaţi, în ordine lexicografică, toate modalităţile de a-l scrie pe n
ca sumă de numere naturale distincte.
Problema | PartitiiNumar1 | Operații I/O |
partitiinumar1.in /partitiinumar1.out
|
---|---|---|---|
Limita timp | 0.5 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #55005767 | Utilizator | |
Fișier | partitiinumar1.cpp | Dimensiune | 354 B |
Data încărcării | 16 Decembrie 2024, 10:40 | Scor / rezultat | Eroare de compilare |
partitiinumar1.cpp:5:1: error: stray '\342' in program ifstream fin(“partitiinumar1.in”); ^ partitiinumar1.cpp:5:1: error: stray '\200' in program partitiinumar1.cpp:5:1: error: stray '\234' in program partitiinumar1.cpp:5:1: error: stray '\342' in program partitiinumar1.cpp:5:1: error: stray '\200' in program partitiinumar1.cpp:5:1: error: stray '\235' in program partitiinumar1.cpp:6:1: error: stray '\342' in program ofstream fout(“partitiinumar1.out”); ^ partitiinumar1.cpp:6:1: error: stray '\200' in program partitiinumar1.cpp:6:1: error: stray '\234' in program partitiinumar1.cpp:6:1: error: stray '\342' in program partitiinumar1.cpp:6:1: error: stray '\200' in program partitiinumar1.cpp:6:1: error: stray '\235' in program partitiinumar1.cpp:10:1: error: stray '\342' in program ) fout << x[i] << “ “; fout <<endl; ^ partitiinumar1.cpp:10:1: error: stray '\200' in program partitiinumar1.cpp:10:1: error: stray '\234' in program partitiinumar1.cpp:10:1: error: stray '\342' in program partitiinumar1.cpp:10:1: error: stray '\200' in program partitiinumar1.cpp:10:1: error: stray '\234' in program partitiinumar1.cpp:5:17: error: 'partitiinumar1' was not declared in this scope ifstream fin(“partitiinumar1.in”); ^ partitiinumar1.cpp:6:18: error: 'partitiinumar1' was not declared in this scope ofstream fout(“partitiinumar1.out”); ^ partitiinumar1.cpp: In function 'void afisare(int)': partitiinumar1.cpp:10:11: error: 'x' was not declared in this scope ) fout << x[i] << “ “; fout <<endl; ^ partitiinumar1.cpp:10:26: error: expected primary-expression before ';' token ) fout << x[i] << “ “; fout <<endl; ^ partitiinumar1.cpp: In function 'void back(int, int)': partitiinumar1.cpp:13:13: error: 'x' was not declared in this scope { for(int i=x[k-1]+1 ; i<=n-s ;i++) { x[k]=i; if(s+x[k]<=n) if( s+x[k] == n ) ^ partitiinumar1.cpp:13:77: error: expected statement at end of input { for(int i=x[k-1]+1 ; i<=n-s ;i++) { x[k]=i; if(s+x[k]<=n) if( s+x[k] == n ) ^ partitiinumar1.cpp:13:77: error: expected '}' at end of input partitiinumar1.cpp:13:77: error: expected '}' at end of input
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema PartitiiNumar1 face parte din prima categorie. Soluția propusă de tine va fi evaluată astfel:
Suma punctajelor acordate pe testele utilizate pentru verificare este 100. Astfel, soluția ta poate obține cel mult 100 de puncte, caz în care se poate considera corectă.