#194
Să se genereze toate anagramele unui cuvânt citit.
| Problema | Anagrame1 | Operații I/O |
anagrame1.in/anagrame1.out
|
|---|---|---|---|
| Limita timp | 0.5 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
| Id soluție | #64072413 | Utilizator | |
| Fișier | anagrame1.cpp | Dimensiune | 611 B |
| Data încărcării | 15 Aprilie 2026, 15:58 | Scor/rezultat | Eroare de compilare |
anagrame1.cpp: In function ‘void back(int)’: anagrame1.cpp:17:8: error: ‘in’ was not declared in this scope; did you mean ‘i’? 17 | in ok=1; | ^~ | i anagrame1.cpp:19:20: error: ‘i’ was not declared in this scope 19 | if(p[j]==s[i]) | ^ anagrame1.cpp:20:9: error: ‘ok’ was not declared in this scope; did you mean ‘k’? 20 | ok=0; | ^~ | k anagrame1.cpp:18:5: warning: this ‘for’ clause does not guard... [-Wmisleading-indentation] 18 | for(int j=0;j<k;j++) | ^~~ anagrame1.cpp:21:9: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘for’ 21 | if(ok){ | ^~ anagrame1.cpp:21:12: error: ‘ok’ was not declared in this scope; did you mean ‘k’? 21 | if(ok){ | ^~ | k anagrame1.cpp:22:16: error: ‘i’ was not declared in this scope 22 | p[k]=s[i]; | ^ anagrame1.cpp:23:18: error: expected ‘;’ before ‘}’ token 23 | back(k+1) | ^ | ; 24 | } | ~ anagrame1.cpp: At global scope: anagrame1.cpp:26:1: error: expected declaration before ‘}’ token 26 | } | ^ anagrame1.cpp: In function ‘int main()’: anagrame1.cpp:34:13: error: expected ‘;’ before ‘:’ token 34 | return 0: | ^ | ; anagrame1.cpp:34:13: error: expected primary-expression before ‘:’ token
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema Anagrame1 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ă.