Problem swords
User G
Submission Time 2024-02-05 20:15:39
Score 0
Max Time N/A
Max Memory N/A

Compile Error

swords.cpp: In function ‘int main()’:
swords.cpp:11:14: error: request for member ‘first’ in ‘swords’, which is of non-class type ‘std::pair<int, int> [n]’
11 | sort(swords.first,swords.first+n);
| ^~~~~
swords.cpp:11:27: error: request for member ‘first’ in ‘swords’, which is of non-class type ‘std::pair<int, int> [n]’
11 | sort(swords.first,swords.first+n);
| ^~~~~
swords.cpp:11:2: error: ‘sort’ was not declared in this scope; did you mean ‘qsort’?
11 | sort(swords.first,swords.first+n);
| ^~~~
| qsort