#3479
Se da un număr n. Calculați ultima cifră a lui \({2}^{n}\).
| Problema | 2lan | Operații I/O |
2lan.in/2lan.out
|
|---|---|---|---|
| Limita timp | 0.1 secunde | Limita memorie |
Total: 0.1 MB
/
Stivă 0.1 MB
|
| Id soluție | #64282604 | Utilizator | |
| Fișier | lan.cpp | Dimensiune | 377 B |
| Data încărcării | 27 Aprilie 2026, 21:53 | Scor/rezultat | Eroare de compilare |
lan.cpp: In function ‘int main()’: lan.cpp:3:5: error: ‘ifstream’ was not declared in this scope 3 | ifstream fin("2lan.in"); | ^~~~~~~~ lan.cpp:4:5: error: ‘ofstream’ was not declared in this scope 4 | ofstream fout("2lan.out"); | ^~~~~~~~ lan.cpp:7:5: error: ‘fin’ was not declared in this scope 7 | fin >> n; | ^~~ lan.cpp:10:9: error: ‘fout’ was not declared in this scope 10 | fout << 1; | ^~~~ lan.cpp:13:9: error: ‘fout’ was not declared in this scope 13 | fout << 2; | ^~~~ lan.cpp:16:9: error: ‘fout’ was not declared in this scope 16 | fout << 4; | ^~~~ lan.cpp:19:9: error: ‘fout’ was not declared in this scope 19 | fout << 8; | ^~~~ lan.cpp:22:9: error: ‘fout’ was not declared in this scope 22 | fout << 6; | ^~~~
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema 2lan 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ă.