Problem prime
User Ethan1L1K1X1
Submission Time 2025-12-09 13:24:32
Score 0
Max Time N/A
Max Memory N/A

Compile Error

prime.cpp: In function ‘int main()’:
prime.cpp:4:2: error: ‘cin’ was not declared in this scope
4 | cin >> x;
| ^~~
prime.cpp:5:17: error: ‘begin’ was not declared in this scope
5 | for (int i : x/2){
| ^
prime.cpp:5:17: error: ‘end’ was not declared in this scope
prime.cpp:6:6: error: expected ‘(’ before ‘x’
6 | if x%i == 0{cout<<"Not Prime";}
| ^
| (
prime.cpp:7:3: error: ‘else’ without a previous ‘if’
7 | else{i++;}}
| ^~~~
prime.cpp:8:2: error: ‘cout’ was not declared in this scope
8 | cout<<"Prime";
| ^~~~