Borderou de evaluare (job #610817)
Utilizator |
|
IP | ascuns |
---|---|---|---|
Problemă | Prime (clasa a 5-a) | Compilator | cpp-32 |
Rundă | lasm_19_10_2021_clasa12 | Status | evaluat |
Dată | 19 oct. 2021 11:59:08 | Scor | 0 |
Raport evaluator
Eroare de compilare:
main.cpp: In function 'int main()':
main.cpp:15:2: error: reference to 'cin' is ambiguous
15 | cin >> x >> n;
| ^~~
In file included from /usr/lib/gcc/i686-pc-linux-gnu/10.3.0/include/g++-v10/i686-pc-linux-gnu/bits/stdc++.h:75,
from main.cpp:1:
/usr/lib/gcc/i686-pc-linux-gnu/10.3.0/include/g++-v10/iostream:60:18: note: candidates are: 'std::istream std::cin'
60 | extern istream cin; /// Linked to standard input
| ^~~
main.cpp:5:10: note: 'std::ifstream cin'
5 | ifstream cin( "prime.in");
| ^~~
main.cpp:21:2: warning: this 'while' clause does not guard... [-Wmisleading-indentation]
21 | while ( maxx[a] == 1 ) a--; s = 0;
| ^~~~~
main.cpp:21:30: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'while'
21 | while ( maxx[a] == 1 ) a--; s = 0;
| ^
main.cpp:29:2: error: reference to 'cout' is ambiguous
29 | cout<< a << e << s;
| ^~~~
In file included from /usr/lib/gcc/i686-pc-linux-gnu/10.3.0/include/g++-v10/i686-pc-linux-gnu/bits/stdc++.h:75,
from main.cpp:1:
/usr/lib/gcc/i686-pc-linux-gnu/10.3.0/include/g++-v10/iostream:61:18: note: candidates are: 'std::ostream std::cout'
61 | extern ostream cout; /// Linked to standard output
| ^~~~
main.cpp:6:10: note: 'std::ofstream cout'
6 | ofstream cout ( "prime.out");
| ^~~~
main.cpp:29:16: error: expected primary-expression before '<<' token
29 | cout<< a << e << s;
| ^~