#3479
2lan
C++
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 | #51235396 | Utilizator | |
Fișier | lan.cpp | Dimensiune | 655 B |
Data încărcării | 31 Mai 2024, 11:54 | Scor / rezultat | Eroare de compilare |
lan.cpp:2:1: error: 'ifstream' does not name a type ifstream fin("2lan.in"); ^ lan.cpp:3:1: error: 'ofstream' does not name a type ofstream fout("2lan.out"); ^ lan.cpp: In function 'int main()': lan.cpp:9:5: error: 'fin' was not declared in this scope fin>>n; ^ lan.cpp:11:6: error: 'fout' was not declared in this scope fout<<1<<endl; ^ lan.cpp:13:6: error: 'fout' was not declared in this scope fout<<2<<endl; ^ lan.cpp:15:6: error: 'fout' was not declared in this scope fout<<4<<endl; ^ lan.cpp:17:6: error: 'fout' was not declared in this scope fout<<8<<endl; ^ lan.cpp:19:6: error: 'fout' was not declared in this scope fout<<6<<endl; ^ lan.cpp:21:6: error: 'fout' was not declared in this scope fout<<2<<endl; ^ lan.cpp:23:6: error: 'fout' was not declared in this scope fout<<4<<endl; ^ lan.cpp:25:6: error: 'fout' was not declared in this scope fout<<8<<endl; ^ lan.cpp:27:6: error: 'fout' was not declared in this scope fout<<6<<endl; ^ lan.cpp:29:6: error: 'fout' was not declared in this scope fout<<2<<endl; ^ lan.cpp:31:6: error: 'fout' was not declared in this scope fout.close(); ^
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ă.