Problem | staircase |
---|---|
User | Daddy |
Submission Time | 2023-12-02 13:16:58 |
Score | 0 |
Max Time | N/A |
Max Memory | N/A |
Owl Get a Life
staircase.cpp: In function ‘int main()’:
staircase.cpp:10:9: error: request for member ‘begin’ in ‘a’, which is of non-class type ‘int [n]’
10 | sort(a.begin(), a.end());
| ^~~~~
staircase.cpp:10:20: error: request for member ‘end’ in ‘a’, which is of non-class type ‘int [n]’
10 | sort(a.begin(), a.end());
| ^~~
staircase.cpp:10:2: error: ‘sort’ was not declared in this scope; did you mean ‘qsort’?
10 | sort(a.begin(), a.end());
| ^~~~
| qsort
staircase.cpp:11:2: error: ‘j’ was not declared in this scope
11 | j=0;
| ^
staircase.cpp:13:10: error: condition declares an array
13 | if(int a[i]==j){
| ^
staircase.cpp:15:16: error: condition declares an array
15 | }else if(int a[i]==j+1){
| ^
staircase.cpp:20:16: error: expected ‘}’ at end of input
20 | }cout<<j<<endl;
|