teams.cpp: In function 'void init(int, int*, int*)':
teams.cpp:30:12: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
30 | while(c1 < seg[2*i].size() or c2 < seg[2*i+1].size()){
| ~~~^~~~~~~~~~~~~~~~~
teams.cpp:30:36: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
30 | while(c1 < seg[2*i].size() or c2 < seg[2*i+1].size()){
| ~~~^~~~~~~~~~~~~~~~~~~
teams.cpp:31:10: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
31 | if(c1 == seg[2*i].size()) seg[i].pb(seg[2*i+1][c2++]);
| ~~~^~~~~~~~~~~~~~~~~~
teams.cpp:32:15: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
32 | else if(c2 == seg[2*i].size()) seg[i].pb(seg[2*i][c1++]);
| ~~~^~~~~~~~~~~~~~~~~~
teams.cpp: In function 'int query(int, int, int)':
teams.cpp:45:67: warning: conversion from '__gnu_cxx::__normal_iterator<int*, std::vector<int> >::difference_type' {aka 'long int'} to 'int' may change value [-Wconversion]
45 | res += seg[l].end()-lower_bound(seg[l].begin(),seg[l].end(),val);
| ^
teams.cpp:50:67: warning: conversion from '__gnu_cxx::__normal_iterator<int*, std::vector<int> >::difference_type' {aka 'long int'} to 'int' may change value [-Wconversion]
50 | res += seg[r].end()-lower_bound(seg[r].begin(),seg[r].end(),val);
| ^
teams.cpp: In function 'int can(int, int*)':
teams.cpp:83:18: warning: conversion from 'long int' to 'int' may change value [-Wconversion]
83 | int ind1 = (j?(lower_bound(a,a+n,make_pair(K[j-1]+1,-1))-a):0);
| ~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
teams.cpp:84:61: warning: conversion from 'long int' to 'int' may change value [-Wconversion]
84 | int ind2 = (lower_bound(a,a+n,make_pair(K[i-1]+1,-1))-a)-1;
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~