#278
Se dau două şiruri cu elemente numere naturale. Determinaţi câte dintre elementele primului şir sunt mai mari decât toate elementele celui de-al doilea şir.
| Problema | MaxMin1 | Operații I/O |
tastatură/ecran
|
|---|---|---|---|
| Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
| Id soluție | #64794098 | Utilizator | |
| Fișier | maxmin1.cpp | Dimensiune | 1.05 KB |
| Data încărcării | 01 Iunie 2026, 19:05 | Scor/rezultat | Eroare de compilare |
maxmin1.cpp:36:5: error: redefinition of ‘int n’ 36 | int n, m; | ^ maxmin1.cpp:4:5: note: ‘int n’ previously declared here 4 | int n, m; | ^ maxmin1.cpp:36:8: error: redefinition of ‘int m’ 36 | int n, m; | ^ maxmin1.cpp:4:8: note: ‘int m’ previously declared here 4 | int n, m; | ^ maxmin1.cpp:37:5: error: redefinition of ‘int x [101]’ 37 | int x[101], y[101], i, maxi = -1, nrElem; | ^ maxmin1.cpp:5:5: note: ‘int x [101]’ previously declared here 5 | int x[101], y[101], i, maxi = -1, nrElem; | ^ maxmin1.cpp:37:13: error: redefinition of ‘int y [101]’ 37 | int x[101], y[101], i, maxi = -1, nrElem; | ^ maxmin1.cpp:5:13: note: ‘int y [101]’ previously declared here 5 | int x[101], y[101], i, maxi = -1, nrElem; | ^ maxmin1.cpp:37:21: error: redefinition of ‘int i’ 37 | int x[101], y[101], i, maxi = -1, nrElem; | ^ maxmin1.cpp:5:21: note: ‘int i’ previously declared here 5 | int x[101], y[101], i, maxi = -1, nrElem; | ^ maxmin1.cpp:37:24: error: redefinition of ‘int maxi’ 37 | int x[101], y[101], i, maxi = -1, nrElem; | ^~~~ maxmin1.cpp:5:24: note: ‘int maxi’ previously defined here 5 | int x[101], y[101], i, maxi = -1, nrElem; | ^~~~ maxmin1.cpp:37:35: error: redefinition of ‘int nrElem’ 37 | int x[101], y[101], i, maxi = -1, nrElem; | ^~~~~~ maxmin1.cpp:5:35: note: ‘int nrElem’ previously declared here 5 | int x[101], y[101], i, maxi = -1, nrElem; | ^~~~~~ maxmin1.cpp:38:5: error: redefinition of ‘int main()’ 38 | int main () | ^~~~ maxmin1.cpp:6:5: note: ‘int main()’ previously defined here 6 | int main () | ^~~~
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema MaxMin1 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ă.