Problem democracy
User skibidininja98
Submission Time 2024-06-21 13:20:54
Score 0
Max Time N/A
Max Memory N/A

Compile Error

democracy.cpp: In function ‘int main()’:
democracy.cpp:7:10: error: ‘i’ was not declared in this scope
7 | cin>>a[i];
| ^
democracy.cpp:25:1: error: expected ‘}’ at end of input
25 | }
| ^
democracy.cpp:21:19: note: to match this ‘{’
21 | if (a[i]==a[j]){
| ^
democracy.cpp:25:1: error: expected ‘}’ at end of input
25 | }
| ^
democracy.cpp:20:29: note: to match this ‘{’
20 | for (int j=i+1;j<5;j++){
| ^
democracy.cpp:25:1: error: expected ‘}’ at end of input
25 | }
| ^
democracy.cpp:18:23: note: to match this ‘{’
18 | for (int i=0;i<5;i++){
| ^
democracy.cpp:25:1: error: expected ‘}’ at end of input
25 | }
| ^
democracy.cpp:12:29: note: to match this ‘{’
12 | for (int j=i+1;j<5;j++){
| ^
de