#3616
Cifrul ADFGX este un cifru care folosește o matrice pătratică 5x5 și o cheie. În matricea pătratică, liniile și coloanele vor fi numerotate cu litere. Avem această matrice ca exemplu.
A D F G X A a b c d e D f g h i j F k l m n o G p q r s t X u v w x y
| Problema | adfgx | Operații I/O |
adfgx.in/adfgx.out
|
|---|---|---|---|
| Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
| Id soluție | #64210879 | Utilizator | |
| Fișier | adfgx.cpp | Dimensiune | 4.05 KB |
| Data încărcării | 23 Aprilie 2026, 09:36 | Scor/rezultat | 0 puncte |
adfgx.cpp: In function ‘std::string encode(std::string&, std::vector<std::vector<char> >&, std::string&)’: adfgx.cpp:34:21: warning: comparison of integer expressions of different signedness: ‘int’ and ‘std::__cxx11::basic_string<char>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare] 34 | if (idx < codes.length()) { | ~~~~^~~~~~~~~~~~~~~~ adfgx.cpp: In function ‘std::string decode(std::string&, std::vector<std::vector<char> >&, std::string&)’: adfgx.cpp:104:19: warning: comparison of integer expressions of different signedness: ‘int’ and ‘std::__cxx11::basic_string<char>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare] 104 | if (j < originalGrid[i].length()) { | ~~^~~~~~~~~~~~~~~~~~~~~~~~~~ adfgx.cpp:112:23: warning: comparison of integer expressions of different signedness: ‘int’ and ‘std::__cxx11::basic_string<char>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare] 112 | for (int i = 0; i < codes.length(); i += 2) { | ~~^~~~~~~~~~~~~~~~
| Test | Timp | Mesaj evaluare | Scor posibil | Scor obținut | ||
|---|---|---|---|---|---|---|
| 0 | 0.001 secunde | Raspuns gresit. | 10 | 0 | ||
| 1 | 0.001 secunde | Raspuns gresit. | 10 | 0 | ||
| 2 | 0.001 secunde | Raspuns gresit. | 10 | 0 | ||
| 3 | 0.001 secunde | Raspuns gresit. | 10 | 0 | ||
| 4 | 0.003 secunde | Raspuns gresit. | 10 | 0 | ||
| 5 | 0.001 secunde | Raspuns gresit. | 10 | 0 | ||
| 6 | 0.001 secunde | Raspuns gresit. | 10 | 0 | ||
| 7 | 0.001 secunde | Raspuns gresit. | 10 | 0 | ||
| 8 | 0.001 secunde | Raspuns gresit. | 10 | 0 | ||
| 9 | 0.001 secunde | Raspuns gresit. | 10 | 0 | ||
| Punctaj total | 0 | |||||
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema adfgx 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ă.