#191
MaxMat
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 | #53895031 | Utilizator | |
Fișier | maxmat.cpp | Dimensiune | 1.05 KB |
Data încărcării | 14 Noiembrie 2024, 10:09 | Scor / rezultat | Eroare de compilare |
maxmat.cpp: In function 'void MaxMAT(int, int, int (*)[100])': maxmat.cpp:30:13: error: reference to 'cout' is ambiguous cout << max << " " << poz << endl; ^ maxmat.cpp:7:10: note: candidates are: std::ofstream cout ofstream cout("maxmat.out"); ^ In file included from maxmat.cpp:1:0: /usr/include/c++/4.8/iostream:61:18: note: std::ostream std::cout extern ostream cout; /// Linked to standard output ^ maxmat.cpp: In function 'void CitireMat(int&, int&, int (*)[100])': maxmat.cpp:37:5: error: reference to 'cin' is ambiguous cin >> n >> m; ^ maxmat.cpp:6:10: note: candidates are: std::ifstream cin ifstream cin("maxmat.in"); ^ In file included from maxmat.cpp:1:0: /usr/include/c++/4.8/iostream:60:18: note: std::istream std::cin extern istream cin; /// Linked to standard input ^ maxmat.cpp:40:13: error: reference to 'cin' is ambiguous cin >> a[i][j]; ^ maxmat.cpp:6:10: note: candidates are: std::ifstream cin ifstream cin("maxmat.in"); ^ In file included from maxmat.cpp:1:0: /usr/include/c++/4.8/iostream:60:18: note: std::istream std::cin extern istream cin; /// Linked to standard input ^ maxmat.cpp: In function 'void AfisareMat(int, int, int (*)[100])': maxmat.cpp:47:13: error: reference to 'cout' is ambiguous cout << a[i][j] << " "; ^ maxmat.cpp:7:10: note: candidates are: std::ofstream cout ofstream cout("maxmat.out"); ^ In file included from maxmat.cpp:1:0: /usr/include/c++/4.8/iostream:61:18: note: std::ostream std::cout extern ostream cout; /// Linked to standard output ^ maxmat.cpp:48:9: error: reference to 'cout' is ambiguous cout << endl; ^ maxmat.cpp:7:10: note: candidates are: std::ofstream cout ofstream cout("maxmat.out"); ^ In file included from maxmat.cpp:1:0: /usr/include/c++/4.8/iostream:61:18: note: std::ostream std::cout extern ostream cout; /// Linked to standard output ^
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ă.