Problem swords
User JamesPearman
Submission Time 2024-02-21 21:25:43
Score 0
Max Time N/A
Max Memory N/A

Compile Error

swords.cpp: In function ‘int main()’:
swords.cpp:18:3: error: ‘vector’ was not declared in this scope
18 | vector<pii>x,y;
| ^~~~~~
swords.cpp:3:1: note: ‘std::vector’ is defined in header ‘<vector>’; did you forget to ‘#include <vector>’?
2 | #include <iostream>
+++ |+#include <vector>
3 | using namespace std;
swords.cpp:18:13: error: expected primary-expression before ‘>’ token
18 | vector<pii>x,y;
| ^
swords.cpp:18:14: error: ‘x’ was not declared in this scope
18 | vector<pii>x,y;
| ^
swords.cpp:18:16: error: ‘y’ was not declared in this scope
18 | vector<pii>x,y;
| ^
swords.cpp:24:3: error: ‘sort’ was not declared in this scope; did you mean ‘qsort’?
24 | sort(x.begin(),x.end(),cmp);//attack
| ^~~~
| qsort
swords.cpp:29:9: error: ‘d’ was not declared in t