event2.cpp: In function 'int dp(int)':
event2.cpp:9:8: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<std::pair<int, int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
9 | if (i == events.size()) return 0;
| ~~^~~~~~~~~~~~~~~~
event2.cpp: In function 'int main()':
event2.cpp:31:27: warning: comparison of integer expressions of different signedness: 'std::vector<int>::size_type' {aka 'long unsigned int'} and 'int' [-Wsign-compare]
31 | if (dp(0) + ans.size() >= K) {
| ~~~~~~~~~~~~~~~~~~~^~~~
event2.cpp:38:18: warning: comparison of integer expressions of different signedness: 'std::vector<int>::size_type' {aka 'long unsigned int'} and 'int' [-Wsign-compare]
38 | if (ans.size() >= K) {
| ~~~~~~~~~~~^~~~
event2.cpp:15:7: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
15 | scanf("%d %d", &N, &K);
| ~~~~~^~~~~~~~~~~~~~~~~
event2.cpp:17:35: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
17 | for (int i = 0; i < N; ++i) scanf("%d %d", &L[i], &R[i]);
| ~~~~~^~~~~~~~~~~~~~~~~~~~~~~