#13
Prefixe
Să se scrie un program care să afişeze prefixele şi sufixele unui cuvânt citit.
Problema | Prefixe | Operații I/O | tastatură/ecran |
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #53715961 | Utilizator | |
Fișier | prefixe.cpp | Dimensiune | 360 B |
Data încărcării | 09 Noiembrie 2024, 13:58 | Scor / rezultat | Eroare de compilare |
prefixe.cpp: In function 'void afis(char*)': prefixe.cpp:11:9: error: 'cout' was not declared in this scope cout<<c<<endl; ^ prefixe.cpp:11:9: note: suggested alternative: In file included from prefixe.cpp:3:0: /usr/include/c++/4.8/iostream:61:18: note: 'std::cout' extern ostream cout; /// Linked to standard output ^ prefixe.cpp:11:18: error: 'endl' was not declared in this scope cout<<c<<endl; ^ prefixe.cpp:11:18: note: suggested alternative: In file included from /usr/include/c++/4.8/iostream:39:0, from prefixe.cpp:3: /usr/include/c++/4.8/ostream:564:5: note: 'std::endl' endl(basic_ostream<_CharT, _Traits>& __os) ^ prefixe.cpp:13:27: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] for(int i=0;i<strlen(s);i++) ^ prefixe.cpp:14:9: error: 'cout' was not declared in this scope cout<<s+i<<endl; ^ prefixe.cpp:14:9: note: suggested alternative: In file included from prefixe.cpp:3:0: /usr/include/c++/4.8/iostream:61:18: note: 'std::cout' extern ostream cout; /// Linked to standard output ^ prefixe.cpp:14:20: error: 'endl' was not declared in this scope cout<<s+i<<endl; ^ prefixe.cpp:14:20: note: suggested alternative: In file included from /usr/include/c++/4.8/iostream:39:0, from prefixe.cpp:3: /usr/include/c++/4.8/ostream:564:5: note: 'std::endl' endl(basic_ostream<_CharT, _Traits>& __os) ^ prefixe.cpp: In function 'int main()': prefixe.cpp:20:1: error: 'cin' was not declared in this scope cin.get(s,256); ^ prefixe.cpp:20:1: note: suggested alternative: In file included from prefixe.cpp:3:0: /usr/include/c++/4.8/iostream:60:18: note: 'std::cin' extern istream cin; /// Linked to standard input ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema Prefixe 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ă.