#206
GenMat1
Scrieţi un program care citeşte de la tastatură două numere naturale nenule n
şi m
şi care construieşte în memorie şi apoi afişează o matrice A
cu n
linii (numerotate de la 1
la n
) şi m
coloane (numerotate de la 1
la m
) cu proprietatea că fiecare element A
ij
memorează cea mai mică dintre valorile indicilor i
şi j
.
Variante Bacalaureat 2009
Problema | GenMat1 | Operații I/O | tastatură/ecran |
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #22616486 | Utilizator | |
Fișier | genmat1.cpp | Dimensiune | 401 B |
Data încărcării | 26 Aprilie 2020, 15:55 | Scor / rezultat | Eroare de compilare |
genmat1.cpp:7:1: error: stray '\302' in program int n, m; ^ genmat1.cpp:7:1: error: stray '\240' in program genmat1.cpp:7:1: error: stray '\302' in program genmat1.cpp:7:1: error: stray '\240' in program genmat1.cpp:7:1: error: stray '\302' in program genmat1.cpp:7:1: error: stray '\240' in program genmat1.cpp:8:1: error: stray '\302' in program cin >> n >> m; ^ genmat1.cpp:8:1: error: stray '\240' in program genmat1.cpp:8:1: error: stray '\302' in program genmat1.cpp:8:1: error: stray '\240' in program genmat1.cpp:8:1: error: stray '\302' in program genmat1.cpp:8:1: error: stray '\240' in program genmat1.cpp:9:1: error: stray '\302' in program for(int i = 1; i <= n; i++) ^ genmat1.cpp:9:1: error: stray '\240' in program genmat1.cpp:9:1: error: stray '\302' in program genmat1.cpp:9:1: error: stray '\240' in program genmat1.cpp:9:1: error: stray '\302' in program genmat1.cpp:9:1: error: stray '\240' in program genmat1.cpp:10:1: error: stray '\302' in program for(int j = 1; j <= m; j++) ^ genmat1.cpp:10:1: error: stray '\240' in program genmat1.cpp:10:1: error: stray '\302' in program genmat1.cpp:10:1: error: stray '\240' in program genmat1.cpp:10:1: error: stray '\302' in program genmat1.cpp:10:1: error: stray '\240' in program genmat1.cpp:10:1: error: stray '\302' in program genmat1.cpp:10:1: error: stray '\240' in program genmat1.cpp:11:1: error: stray '\302' in program a[i][j] = min (i, j); ^ genmat1.cpp:11:1: error: stray '\240' in program genmat1.cpp:11:1: error: stray '\302' in program genmat1.cpp:11:1: error: stray '\240' in program genmat1.cpp:11:1: error: stray '\302' in program genmat1.cpp:11:1: error: stray '\240' in program genmat1.cpp:11:1: error: stray '\302' in program genmat1.cpp:11:1: error: stray '\240' in program genmat1.cpp:11:1: error: stray '\302' in program genmat1.cpp:11:1: error: stray '\240' in program genmat1.cpp:11:1: error: stray '\302' in program genmat1.cpp:11:1: error: stray '\240' in program genmat1.cpp:12:1: error: stray '\302' in program for(int i = 1; i <= n; i++) { ^ genmat1.cpp:12:1: error: stray '\240' in program genmat1.cpp:12:1: error: stray '\302' in program genmat1.cpp:12:1: error: stray '\240' in program genmat1.cpp:12:1: error: stray '\302' in program genmat1.cpp:12:1: error: stray '\240' in program genmat1.cpp:13:1: error: stray '\302' in program for(int j = 1; j <= m; j++) ^ genmat1.cpp:13:1: error: stray '\240' in program genmat1.cpp:13:1: error: stray '\302' in program genmat1.cpp:13:1: error: stray '\240' in program genmat1.cpp:13:1: error: stray '\302' in program genmat1.cpp:13:1: error: stray '\240' in program genmat1.cpp:13:1: error: stray '\302' in program genmat1.cpp:13:1: error: stray '\240' in program genmat1.cpp:14:1: error: stray '\302' in program cout << a[i][j] <<" "; ^ genmat1.cpp:14:1: error: stray '\240' in program genmat1.cpp:14:1: error: stray '\302' in program genmat1.cpp:14:1: error: stray '\240' in program genmat1.cpp:14:1: error: stray '\302' in program genmat1.cpp:14:1: error: stray '\240' in program genmat1.cpp:14:1: error: stray '\302' in program genmat1.cpp:14:1: error: stray '\240' in program genmat1.cpp:14:1: error: stray '\302' in program genmat1.cpp:14:1: error: stray '\240' in program genmat1.cpp:14:1: error: stray '\302' in program genmat1.cpp:14:1: error: stray '\240' in program genmat1.cpp:15:1: error: stray '\302' in program cout << endl; ^ genmat1.cpp:15:1: error: stray '\240' in program genmat1.cpp:15:1: error: stray '\302' in program genmat1.cpp:15:1: error: stray '\240' in program genmat1.cpp:15:1: error: stray '\302' in program genmat1.cpp:15:1: error: stray '\240' in program genmat1.cpp:15:1: error: stray '\302' in program genmat1.cpp:15:1: error: stray '\240' in program genmat1.cpp:16:1: error: stray '\302' in program } ^ genmat1.cpp:16:1: error: stray '\240' in program genmat1.cpp:16:1: error: stray '\302' in program genmat1.cpp:16:1: error: stray '\240' in program genmat1.cpp:16:1: error: stray '\302' in program genmat1.cpp:16:1: error: stray '\240' in program genmat1.cpp:17:1: error: stray '\302' in program return 0; ^ genmat1.cpp:17:1: error: stray '\240' in program genmat1.cpp:17:1: error: stray '\302' in program genmat1.cpp:17:1: error: stray '\240' in program genmat1.cpp:17:1: error: stray '\302' in program genmat1.cpp:17:1: error: stray '\240' in program
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema GenMat1 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ă.