Problem sort2
User OSoverspike
Submission Time 2025-11-14 01:09:46
Score 0
Max Time N/A
Max Memory N/A

Compile Error

sort2.cpp:1:1: error: ‘import’ does not name a type
1 | import <bits/stdc++.h>
| ^~~~~~
sort2.cpp: In function ‘int main()’:
sort2.cpp:5:2: error: ‘cin’ was not declared in this scope
5 | cin >> n;
| ^~~
sort2.cpp:7:6: error: expected ‘(’ before ‘i’
7 | for i in range(0, n) {
| ^
| (
sort2.cpp:7:6: error: ‘i’ was not declared in this scope
sort2.cpp:10:7: error: ‘sort’ is not a member of ‘std’
10 | std::sort(input.begin(), input.begin()+n, std::greater<int>());
| ^~~~
sort2.cpp:10:12: error: ‘input’ was not declared in this scope; did you mean ‘int’?
10 | std::sort(input.begin(), input.begin()+n, std::greater<int>());
| ^~~~~
| int
sort2.cpp:10:49: error: ‘greater’ is not a member of ‘std’
10 | std::sort(input.begin(), input.begin()+n, std::greater<int>());
|