#68
CifraMaxima
Să se scrie un program care să determine cea mai mare cifră a unui număr natural citit de la tastatură.
Problema | CifraMaxima | Operații I/O | tastatură/ecran |
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #54190309 | Utilizator | |
Fișier | ciframaxima.cpp | Dimensiune | 374 B |
Data încărcării | 21 Noiembrie 2024, 17:57 | Scor / rezultat | Eroare de compilare |
ciframaxima.cpp:1:10: error: #include expects "FILENAME" or <FILENAME> #include ‹iostream> using namespace std; ^ ciframaxima.cpp:9:1: error: stray '\357' in program { ^ ciframaxima.cpp:9:1: error: stray '\275' in program ciframaxima.cpp:9:1: error: stray '\233' in program ciframaxima.cpp:12:1: error: stray '\357' in program } ^ ciframaxima.cpp:12:1: error: stray '\275' in program ciframaxima.cpp:12:1: error: stray '\235' in program ciframaxima.cpp:18:1: error: stray '\357' in program } ^ ciframaxima.cpp:18:1: error: stray '\275' in program ciframaxima.cpp:18:1: error: stray '\235' in program ciframaxima.cpp:27:1: error: stray '\357' in program sol=b; ^ ciframaxima.cpp:27:1: error: stray '\274' in program ciframaxima.cpp:27:1: error: stray '\233' in program ciframaxima.cpp:32:1: error: stray '\357' in program } ^ ciframaxima.cpp:32:1: error: stray '\275' in program ciframaxima.cpp:32:1: error: stray '\235' in program ciframaxima.cpp: In function 'int main()': ciframaxima.cpp:6:5: error: 'cin' was not declared in this scope cin>>a>>b; ^ ciframaxima.cpp:10:1: error: 'og' was not declared in this scope og la=ogla*10+a1%10; ^ ciframaxima.cpp:10:4: error: expected ';' before 'la' og la=ogla*10+a1%10; ^ ciframaxima.cpp:11:5: error: 'a1' was not declared in this scope a1/=10; ^ ciframaxima.cpp:14:8: error: 'bl' was not declared in this scope while (bl) ^ ciframaxima.cpp:16:1: error: 'og' was not declared in this scope og lb=oglb*10+b1%10; ^ ciframaxima.cpp:16:4: error: expected ';' before 'lb' og lb=oglb*10+b1%10; ^ ciframaxima.cpp:28:1: error: expected ';' before '}' token } ^ ciframaxima.cpp:23:4: warning: suggest explicit braces to avoid ambiguous 'else' [-Wparentheses] if (ogla==oglb) ^ ciframaxima.cpp:29:1: error: 'else' without a previous 'if' else sol=b; ^ ciframaxima.cpp:29:6: error: 'sol' was not declared in this scope else sol=b; ^ ciframaxima.cpp:30:1: error: 'cout' was not declared in this scope cout<<sol; ^ ciframaxima.cpp:31:13: error: expected '}' at end of input return 0; ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema CifraMaxima 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ă.