#3808
Să se cripteze sau să se decripteze un mesaj folosind cifrul ADFGVX.
cifrul ADFGVX
| Problema | ADFGVX | Operații I/O |
adfgvx.in/adfgvx.out
|
|---|---|---|---|
| Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
| Id soluție | #63809552 | Utilizator | |
| Fișier | adfgvx.cpp | Dimensiune | 2.04 KB |
| Data încărcării | 19 Martie 2026, 16:38 | Scor/rezultat | 100 puncte |
adfgvx.cpp: In function 'int main()': adfgvx.cpp:17:17: warning: array subscript has type 'char' [-Wchar-subscripts] character[ch]+="A"; ^ adfgvx.cpp:19:17: warning: array subscript has type 'char' [-Wchar-subscripts] character[ch]+="D"; ^ adfgvx.cpp:21:17: warning: array subscript has type 'char' [-Wchar-subscripts] character[ch]+="F"; ^ adfgvx.cpp:23:17: warning: array subscript has type 'char' [-Wchar-subscripts] character[ch]+="G"; ^ adfgvx.cpp:25:17: warning: array subscript has type 'char' [-Wchar-subscripts] character[ch]+="V"; ^ adfgvx.cpp:27:17: warning: array subscript has type 'char' [-Wchar-subscripts] character[ch]+="X"; ^ adfgvx.cpp:29:17: warning: array subscript has type 'char' [-Wchar-subscripts] character[ch]+="A"; ^ adfgvx.cpp:31:17: warning: array subscript has type 'char' [-Wchar-subscripts] character[ch]+="D"; ^ adfgvx.cpp:33:17: warning: array subscript has type 'char' [-Wchar-subscripts] character[ch]+="F"; ^ adfgvx.cpp:35:17: warning: array subscript has type 'char' [-Wchar-subscripts] character[ch]+="G"; ^ adfgvx.cpp:37:17: warning: array subscript has type 'char' [-Wchar-subscripts] character[ch]+="V"; ^ adfgvx.cpp:39:17: warning: array subscript has type 'char' [-Wchar-subscripts] character[ch]+="X"; ^ adfgvx.cpp:40:27: warning: array subscript has type 'char' [-Wchar-subscripts] string cuv=character[ch]; ^ adfgvx.cpp:45:29: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] for(int i=0; i<mesaj.size(); i++) ^ adfgvx.cpp:46:34: warning: array subscript has type 'char' [-Wchar-subscripts] criptmesaj+=character[mesaj[i]]; ^ adfgvx.cpp:47:34: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] for(int i=0; i<criptmesaj.size(); i++) ^ adfgvx.cpp:51:31: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] { for(int j=0; j<cheie.size(); j++) ^ adfgvx.cpp:53:53: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] { for(int i=0; i<criptmesaj.size()/cheie.size()+1; i++) ^ adfgvx.cpp:68:32: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] { for(int i=0; i<length.size(); i++) ^ adfgvx.cpp:71:28: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] for(int k=0; k<a.size(); k++) ^ adfgvx.cpp:79:31: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] for(int j=0; j<length.size(); j++) ^ adfgvx.cpp:82:36: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] for(int j=0; j<decriptmesaj.size(); j+=2) ^
| Test | Timp | Mesaj evaluare | Scor posibil | Scor obținut | ||
|---|---|---|---|---|---|---|
| 1 | 0 secunde | OK. | 5 | 5 | Exemplu | |
| 2 | 0 secunde | OK. | 5 | 5 | Exemplu | |
| 3 | 0 secunde | OK. | 10 | 10 | ||
| 4 | 0 secunde | OK. | 10 | 10 | ||
| 5 | 0 secunde | OK. | 20 | 20 | ||
| 6 | 0 secunde | OK. | 20 | 20 | ||
| 7 | 0 secunde | OK. | 10 | 10 | ||
| 8 | 0 secunde | OK. | 10 | 10 | ||
| 9 | 0 secunde | OK. | 5 | 5 | ||
| 10 | 0 secunde | OK. | 5 | 5 | ||
| Punctaj total | 100 | |||||
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema ADFGVX 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ă.