#3275
nrSumCifMax
Se dau 3
numere naturale, fiecare având câte două cifre. Afișați-le pe acelea care au suma cifrelor maximă.
CNFB - Concurs de pregatire, clasa a 5-a
Problema | nrSumCifMax | Operații I/O | tastatură/ecran |
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #50557029 | Utilizator | |
Fișier | nrsumcifmax.cpp | Dimensiune | 396 B |
Data încărcării | 15 Aprilie 2024, 10:17 | Scor / rezultat | Eroare de compilare |
nrsumcifmax.cpp: In function 'int main()': nrsumcifmax.cpp:11:29: error: overloaded function with no contextual type information if(s1>=s2 && s1>=s3) max=s1; ^ nrsumcifmax.cpp:12:34: error: overloaded function with no contextual type information else if(s2>=s1 && s2>=s3) max=s2; ^ nrsumcifmax.cpp:13:35: error: overloaded function with no contextual type information else if (s3>=s1 && s3>=s2) max=s3; ^ nrsumcifmax.cpp:14:14: error: invalid operands of types '<unresolved overloaded function type>' and 'int' to binary 'operator==' if (max==s1) cout<<a<<" "; ^ nrsumcifmax.cpp:15:14: error: invalid operands of types '<unresolved overloaded function type>' and 'int' to binary 'operator==' if (max==s2) cout<<b<<" "; ^ nrsumcifmax.cpp:16:14: error: invalid operands of types '<unresolved overloaded function type>' and 'int' to binary 'operator==' if (max==s3) cout<<c; ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema nrSumCifMax 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ă.