Borderou de evaluare (job #825466)
| Utilizator |
|
IP | ascuns |
|---|---|---|---|
| Problemă | Colecție (clasa a 5-a) | Compilator | cpp-32 |
| Rundă | Arhiva de probleme | Status | evaluat |
| Dată | 21 mai 2025 16:20:40 | Scor | 0 |
Raport evaluator
Eroare de compilare:
main.cpp: In function 'int main()':
main.cpp:7:5: error: 'ifstream' was not declared in this scope; did you mean 'std::ifstream'?
7 | ifstream cin("colectie.in");
| ^~~~~~~~
| std::ifstream
In file included from /usr/lib/gcc/i686-pc-linux-gnu/14/include/g++-v14/ios:40,
from /usr/lib/gcc/i686-pc-linux-gnu/14/include/g++-v14/istream:40,
from /usr/lib/gcc/i686-pc-linux-gnu/14/include/g++-v14/fstream:40,
from main.cpp:1:
/usr/lib/gcc/i686-pc-linux-gnu/14/include/g++-v14/iosfwd:164:41: note: 'std::ifstream' declared here
164 | typedef basic_ifstream<char> ifstream;
| ^~~~~~~~
main.cpp:8:5: error: 'cin' was not declared in this scope; did you mean 'fin'?
8 | cin >> n >> m >> p;
| ^~~
| fin
main.cpp:30:5: error: 'ofstream' was not declared in this scope; did you mean 'std::ofstream'?
30 | ofstream cout("colectie.out");
| ^~~~~~~~
| std::ofstream
/usr/lib/gcc/i686-pc-linux-gnu/14/include/g++-v14/iosfwd:167:41: note: 'std::ofstream' declared here
167 | typedef basic_ofstream<char> ofstream;
| ^~~~~~~~
main.cpp:32:9: error: 'cout' was not declared in this scope; did you mean 'fout'?
32 | cout << "Niciunul";
| ^~~~
| fout
main.cpp:34:9: error: 'cout' was not declared in this scope; did you mean 'fout'?
34 | cout << "Dorel " << scordorel - scorfanel;
| ^~~~
| fout
main.cpp:36:9: error: 'cout' was not declared in this scope; did you mean 'fout'?
36 | cout << "Fanel " << scorfanel - scordorel;
| ^~~~
| fout
main.cpp:37:5: error: 'cout' was not declared in this scope; did you mean 'fout'?
37 | cout.close();
| ^~~~
| fout
main.cpp:5:11: warning: unused variable 'fin' [-Wunused-variable]
5 | FILE *fin, *fout;
| ^~~
main.cpp:5:17: warning: unused variable 'fout' [-Wunused-variable]
5 | FILE *fin, *fout;
| ^~~~