cc1plus: error: '::main' must return 'int'
tabletennis.cpp: In function 'int main()':
tabletennis.cpp:18:5: error: 'cin' was not declared in this scope
18 | cin >> n >> k;
| ^~~
tabletennis.cpp:5:1: note: 'std::cin' is defined in header '<iostream>'; did you forget to '#include <iostream>'?
4 | #include <cmath>
+++ |+#include <iostream>
5 | #define nmax 160000
tabletennis.cpp:44:25: error: 'cout' was not declared in this scope
44 | cout << sol[i].first << " ";
| ^~~~
tabletennis.cpp:44:25: note: 'std::cout' is defined in header '<iostream>'; did you forget to '#include <iostream>'?
tabletennis.cpp:46:25: error: 'cout' was not declared in this scope
46 | cout << sol[i].second << " ";
| ^~~~
tabletennis.cpp:46:25: note: 'std::cout' is defined in header '<iostream>'; did you forget to '#include <iostream>'?
tabletennis.cpp:17:18: warning: unused variable 'j' [-Wunused-variable]
17 | int n, k, i, j, x, y, st, dr, s, p;
| ^