#213
Scrieţi un program care citeşte de la tastatură un număr natural nenul n
construieşte un tablou bidimensional de dimensiune n
în care fiecare element este egal cu ultima cifră a produsului indicilor.
Variante Bacalaureat 2009
Problema | GenMat4 | Operații I/O |
![]() |
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #58144592 | Utilizator | |
Fișier | genmat4.cpp | Dimensiune | 329 B |
Data încărcării | 16 Mai 2025, 10:38 | Scor / rezultat | Eroare de compilare |
genmat4.cpp:1:10: error: #include expects "FILENAME" or <FILENAME> #include iostream ^ genmat4.cpp:15:25: error: empty character constant cout<<a[i][j]<< ''; ^ genmat4.cpp: In function 'int main()': genmat4.cpp:6:5: error: 'cin' was not declared in this scope cin>>n; ^ genmat4.cpp:7:14: warning: right operand of comma operator has no effect [-Wunused-value] for(i=1,i<=n,i++) ^ genmat4.cpp:7:21: error: expected ';' before ')' token for(i=1,i<=n,i++) ^ genmat4.cpp:13:5: error: expected primary-expression before 'for' for(i=1,i<=n,i++) ^ genmat4.cpp:13:5: error: expected ';' before 'for' genmat4.cpp:13:5: error: expected primary-expression before 'for' genmat4.cpp:13:5: error: expected ')' before 'for' genmat4.cpp:13:14: warning: right operand of comma operator has no effect [-Wunused-value] for(i=1,i<=n,i++) ^ genmat4.cpp:13:21: error: expected ';' before ')' token for(i=1,i<=n,i++) ^ genmat4.cpp:17:10: error: 'cout' was not declared in this scope cout<< '\n'; ^ genmat4.cpp:21:1: error: expected primary-expression before '}' token } return 0; ^ genmat4.cpp:21:1: error: expected ')' before '}' token genmat4.cpp:21:1: error: expected primary-expression before '}' token genmat4.cpp:21:1: error: expected ';' before '}' token genmat4.cpp: At global scope: genmat4.cpp:21:3: error: expected unqualified-id before 'return' } return 0; ^ genmat4.cpp:22:1: error: expected declaration before '}' token } ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema GenMat4 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ă.