shortcut.cpp: In function 'bool ok(ll)':
shortcut.cpp:26:25: error: no match for 'operator[]' (operand types are 'std::pair<long long int, int>' and 'int')
int i = o_events[it].sd;
^
shortcut.cpp:28:38: error: no match for 'operator[]' (operand types are 'std::pair<long long int, int>' and 'int')
while (ptr < n && mx + events[ptr].ft < -pf[i] + dst[i])
^
shortcut.cpp: In function 'long long int find_shortcut(int, std::vector<int>, std::vector<int>, int)':
shortcut.cpp:114:15: error: no match for 'operator[]' (operand types are 'std::pair<long long int, int>' and 'int')
events[i] = MP(-pf[i] - dst[i], i);
^
shortcut.cpp:115:17: error: no match for 'operator[]' (operand types are 'std::pair<long long int, int>' and 'int')
o_events[i]= MP(-pf[i] + dst[i], i);
^
shortcut.cpp:3:18: error: 'struct std::pair<long long int, int>' has no member named 'begin'
#define all(x) x.begin(),x.end()
^
shortcut.cpp:118:10: note: in expansion of macro 'all'
sort(all(events));
^~~
shortcut.cpp:3:28: error: 'struct std::pair<long long int, int>' has no member named 'end'; did you mean 'second'?
#define all(x) x.begin(),x.end()
^
shortcut.cpp:118:10: note: in expansion of macro 'all'
sort(all(events));
^~~
shortcut.cpp:3:18: error: 'struct std::pair<long long int, int>' has no member named 'begin'
#define all(x) x.begin(),x.end()
^
shortcut.cpp:119:10: note: in expansion of macro 'all'
sort(all(o_events));
^~~
shortcut.cpp:3:28: error: 'struct std::pair<long long int, int>' has no member named 'end'; did you mean 'second'?
#define all(x) x.begin(),x.end()
^
shortcut.cpp:119:10: note: in expansion of macro 'all'
sort(all(o_events));
^~~
shortcut.cpp:125:23: error: no match for 'operator[]' (operand types are 'std::pair<long long int, int>' and 'int')
int j = events[it - 1].sd;
^