#1922
Se dau numerele naturale N și X. Aflați dacă N este divizibil cu 2X și dacă N este divizibil cu 5X.
| Problema | Nmod25 | Operații I/O |
nmod25.in/nmod25.out
|
|---|---|---|---|
| Limita timp | 0.01 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
| Id soluție | #64475780 | Utilizator | |
| Fișier | nmod25.cpp | Dimensiune | 2.14 KB |
| Data încărcării | 09 Mai 2026, 13:48 | Scor/rezultat | 100 puncte |
nmod25.cpp: In function ‘bignum subtract(bignum&, bignum&)’: nmod25.cpp:50:27: warning: comparison of integer expressions of different signedness: ‘int’ and ‘std::vector<int>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare] 50 | for (int i = 0; i < x.size(); ++i) { | ~~^~~~~~~~~~ nmod25.cpp:52:23: warning: comparison of integer expressions of different signedness: ‘int’ and ‘std::vector<int>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare] 52 | if (i < y.size()) cif = y[i]; | ~~^~~~~~~~~~ nmod25.cpp: In function ‘bignum multiply(bignum&, bignum&)’: nmod25.cpp:85:27: warning: comparison of integer expressions of different signedness: ‘int’ and ‘std::vector<int>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare] 85 | for (int i = 0; i < x.size(); ++i) { | ~~^~~~~~~~~~ nmod25.cpp:87:35: warning: comparison of integer expressions of different signedness: ‘int’ and ‘std::vector<int>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare] 87 | for (int j = 0; j < y.size() or carry; ++j) { | ~~^~~~~~~~~~ nmod25.cpp:89:31: warning: comparison of integer expressions of different signedness: ‘int’ and ‘std::vector<int>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare] 89 | if (j < y.size()) cif = y[j]; | ~~^~~~~~~~~~ nmod25.cpp: In function ‘int main()’: nmod25.cpp:109:50: warning: comparison of integer expressions of different signedness: ‘int’ and ‘std::__cxx11::basic_string<char>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare] 109 | for (int i = max(0,(int)z.size() - n); i < z.size(); ++i) { | ~~^~~~~~~~~~
| Test | Timp | Mesaj evaluare | Scor posibil | Scor obținut | ||
|---|---|---|---|---|---|---|
| 1 | 0.002 secunde | OK. | 15 | 15 | Exemplu | |
| 2 | 0.002 secunde | OK. | 20 | 20 | ||
| 3 | 0.002 secunde | OK. | 25 | 25 | ||
| 4 | 0.001 secunde | OK. | 20 | 20 | ||
| 5 | 0.001 secunde | OK. | 20 | 20 | ||
| Punctaj total | 100 | |||||
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema Nmod25 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ă.