segments.cpp: In function 'long long int rec(long long int, long long int, long long int)':
segments.cpp:40:15: warning: comparison of integer expressions of different signedness: 'long long int' and 'std::vector<std::pair<long long int, long long int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
40 | for (i=0;i<v[j].size();++i){
| ~^~~~~~~~~~~~
segments.cpp: At global scope:
segments.cpp:48:6: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
48 | main(){
| ^
segments.cpp: In function 'int main()':
segments.cpp:9:23: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
9 | #define scan1(a) scanf("%lld",&a);
| ~~~~~^~~~~~~~~~~
segments.cpp:50:5: note: in expansion of macro 'scan1'
50 | scan1(n)
| ^~~~~
segments.cpp:9:23: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
9 | #define scan1(a) scanf("%lld",&a);
| ~~~~~^~~~~~~~~~~
segments.cpp:53:9: note: in expansion of macro 'scan1'
53 | scan1(q[i])
| ^~~~~