#210
Să se parcurgă în sensul acelor de ceasornic chenarul exterior al unei matrice pătratice.
Variante Bacalaureat 2009
Problema | Chenar | Operații I/O |
![]() chenar.in /chenar.out
|
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #57772404 | Utilizator | |
Fișier | chenar.cpp | Dimensiune | 414 B |
Data încărcării | 15 Aprilie 2025, 13:36 | Scor / rezultat | Eroare de compilare |
chenar.cpp:5:1: error: expected ',' or ';' before 'ofstream' ofstream g("chenar.out") ^ chenar.cpp: In function 'int main()': chenar.cpp:8:5: error: 'cin' was not declared in this scope { cin>>n; ^ chenar.cpp:8:10: error: 'n' was not declared in this scope { cin>>n; ^ chenar.cpp:9:9: error: 'i' was not declared in this scope for(i=1;i<=n;i++) ^ chenar.cpp:10:13: error: 'j' was not declared in this scope for(j=1;j<=n;j++) ^ chenar.cpp:11:8: error: 'a' was not declared in this scope f>>a[i][j]; ^ chenar.cpp:12:9: error: 'j' was not declared in this scope for(j=1;j<=n;j++) ^ chenar.cpp:13:9: error: 'g' was not declared in this scope g<<a[i][j]; ^ chenar.cpp:13:12: error: 'a' was not declared in this scope g<<a[i][j]; ^ chenar.cpp:13:14: error: 'i' was not declared in this scope g<<a[i][j]; ^ chenar.cpp:14:9: error: 'i' was not declared in this scope for(i=2;i<-n;i++) ^ chenar.cpp:15:9: error: 'g' was not declared in this scope g<<a[i][n]; ^ chenar.cpp:15:12: error: 'a' was not declared in this scope g<<a[i][n]; ^ chenar.cpp:16:9: error: 'j' was not declared in this scope for(j=n=1;j>=1;j--) ^ chenar.cpp:17:9: error: 'g' was not declared in this scope g<<a[n][i]; ^ chenar.cpp:17:12: error: 'a' was not declared in this scope g<<a[n][i]; ^ chenar.cpp:17:17: error: 'i' was not declared in this scope g<<a[n][i]; ^ chenar.cpp:18:9: error: 'i' was not declared in this scope for(i=n-1;i>=2;i--) ^ chenar.cpp:19:9: error: 'g' was not declared in this scope g<<a[i][1]; ^ chenar.cpp:19:12: error: 'a' was not declared in this scope g<<a[i][1]; ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema Chenar 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ă.