#191
Să se determine, pentru fiecare linie a unei matrice, elementul maxim și indicele coloanei pe care se află.
| Problema | MaxMat | Operații I/O |
maxmat.in/maxmat.out
|
|---|---|---|---|
| Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
| Id soluție | #64548967 | Utilizator | |
| Fișier | maxmat.cpp | Dimensiune | 538 B |
| Data încărcării | 13 Mai 2026, 17:45 | Scor/rezultat | Eroare de compilare |
maxmat.cpp:4:15: error: expected unqualified-id before string constant 4 | ifstream ("maxmat.in"); | ^~~~~~~~~~~ maxmat.cpp:4:15: error: expected ‘)’ before string constant 4 | ifstream ("maxmat.in"); | ~^~~~~~~~~~~ | ) maxmat.cpp:5:15: error: expected unqualified-id before string constant 5 | ofstream ("maxmat.out"); | ^~~~~~~~~~~~ maxmat.cpp:5:15: error: expected ‘)’ before string constant 5 | ofstream ("maxmat.out"); | ~^~~~~~~~~~~~ | ) maxmat.cpp: In function ‘int main()’: maxmat.cpp:11:5: error: ‘fin’ was not declared in this scope; did you mean ‘sin’? 11 | fin>>n>>m; | ^~~ | sin maxmat.cpp:12:5: warning: this ‘for’ clause does not guard... [-Wmisleading-indentation] 12 | for(i=1;i<=n;i++) | ^~~ maxmat.cpp:15:9: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘for’ 15 | int mx,ind; | ^~~ maxmat.cpp:21:13: error: ‘fout’ was not declared in this scope 21 | fout<<mx<<" "<<ind<<"\n"; | ^~~~
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema MaxMat 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ă.