Problem xmas
User Yizhou
Submission Time 2024-10-11 13:41:26
Score 0
Max Time N/A
Max Memory N/A

Compile Error

xmas.cpp:7:1: error: ‘cin’ does not name a type; did you mean ‘sin’?
7 | cin<<n;
| ^~~
| sin
xmas.cpp:8:20: error: array bound is not an integer constant before ‘]’ token
8 | pair<int, int>arr[n];
| ^
xmas.cpp: In function ‘int main()’:
xmas.cpp:14:8: error: ‘arr’ was not declared in this scope
14 | cin>>arr[i-1].first;
| ^~~
xmas.cpp:17:7: error: ‘arr’ was not declared in this scope
17 | sort(arr.begin(),arr.end(),cmp);
| ^~~