#452
cifimp
Se citește de la tastatură un număr natural de 3
cifre. Să se determine câte cifre impare conține.
Problema | cifimp | Operații I/O | tastatură/ecran |
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #53842410 | Utilizator | |
Fișier | cifimp.cpp | Dimensiune | 423 B |
Data încărcării | 12 Noiembrie 2024, 23:28 | Scor / rezultat | Eroare de compilare |
cifimp.cpp:2:7: error: expected nested-name-specifier before 'namespcee' using namespcee std; ^ cifimp.cpp:2:7: error: 'namespcee' has not been declared cifimp.cpp:2:17: error: expected ';' before 'std' using namespcee std; ^ cifimp.cpp:2:17: error: 'std' does not name a type cifimp.cpp: In function 'int main()': cifimp.cpp:6:5: error: 'cin' was not declared in this scope cin>>n; ^ cifimp.cpp:6:5: note: suggested alternative: In file included from cifimp.cpp:1:0: /usr/include/c++/4.8/iostream:60:18: note: 'std::cin' extern istream cin; /// Linked to standard input ^ cifimp.cpp:10:41: error: lvalue required as left operand of assignment if (cif1%2==1 && cif2%2==1 && cif3%2=1) ^ cifimp.cpp:11:9: error: 'cout' was not declared in this scope cout<<3; ^ cifimp.cpp:11:9: note: suggested alternative: In file included from cifimp.cpp:1:0: /usr/include/c++/4.8/iostream:61:18: note: 'std::cout' extern ostream cout; /// Linked to standard output ^ cifimp.cpp:12:24: warning: suggest parentheses around '&&' within '||' [-Wparentheses] else if (cif1%2==1 && cif2%2==1 || cif2%2==1 && cif3%2==1) ^ cifimp.cpp:13:9: error: 'cout' was not declared in this scope cout<<2; ^ cifimp.cpp:13:9: note: suggested alternative: In file included from cifimp.cpp:1:0: /usr/include/c++/4.8/iostream:61:18: note: 'std::cout' extern ostream cout; /// Linked to standard output ^ cifimp.cpp:15:9: error: 'cout' was not declared in this scope cout<<1; ^ cifimp.cpp:15:9: note: suggested alternative: In file included from cifimp.cpp:1:0: /usr/include/c++/4.8/iostream:61:18: note: 'std::cout' extern ostream cout; /// Linked to standard output ^ cifimp.cpp:16:14: error: 'cout' was not declared in this scope else cout<<0; ^ cifimp.cpp:16:14: note: suggested alternative: In file included from cifimp.cpp:1:0: /usr/include/c++/4.8/iostream:61:18: note: 'std::cout' extern ostream cout; /// Linked to standard output ^ cifimp.cpp:17:17: error: expected '}' at end of input return 0; ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema cifimp 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ă.