#88
Palindrom
Să se verifice dacă un cuvânt dat este palindrom.
Problema | Palindrom | Operații I/O |
palindrom.in /palindrom.out
|
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #8845484 | Utilizator | |
Fișier | palindrom.cpp | Dimensiune | 513 B |
Data încărcării | 15 Martie 2018, 09:19 | Scor / rezultat | Eroare de compilare |
palindrom.cpp: In function 'int main()': palindrom.cpp:5:5: error: 'ifstream' was not declared in this scope ifstream f("palindrom.in"); ^ palindrom.cpp:5:14: error: expected ';' before 'f' ifstream f("palindrom.in"); ^ palindrom.cpp:6:5: error: 'ofstream' was not declared in this scope ofstream g("palindrom.out"); ^ palindrom.cpp:6:14: error: expected ';' before 'g' ofstream g("palindrom.out"); ^ palindrom.cpp:7:5: error: 'f' was not declared in this scope f>>n; ^ palindrom.cpp:12:23: error: 'strlen' was not declared in this scope for(j=strlen(a);j>=0;j--) ^ palindrom.cpp:16:17: error: 'cout' was not declared in this scope cout<<k<<endl; ^ palindrom.cpp:16:26: error: 'endl' was not declared in this scope cout<<k<<endl; ^ palindrom.cpp:18:22: error: 'strcmp' was not declared in this scope if(strcmp(a,b)==0) ^ palindrom.cpp:19:13: error: 'g' was not declared in this scope g<<"1"<<endl; ^ palindrom.cpp:19:21: error: 'endl' was not declared in this scope g<<"1"<<endl; ^ palindrom.cpp:20:22: error: 'strcmp' was not declared in this scope if(strcmp(a,b)!=0) ^ palindrom.cpp:21:13: error: 'g' was not declared in this scope g<<"0"<<endl; ^ palindrom.cpp:21:21: error: 'endl' was not declared in this scope g<<"0"<<endl; ^ palindrom.cpp:24:5: error: 'g' was not declared in this scope g.close(); ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema Palindrom 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ă.