long_mansion.cpp: In function 'bool test(int, int, int)':
long_mansion.cpp:18:9: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   18 |     if(p<seen[val].size()&&seen[val][p]<=r)return 1;
      |        ~^~~~~~~~~~~~~~~~~
long_mansion.cpp: In function 'int main()':
long_mansion.cpp:24:10: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
   24 |     scanf("%i",&n);
      |     ~~~~~^~~~~~~~~
long_mansion.cpp:26:30: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
   26 |     for(int i=1;i<n;i++)scanf("%i",&inp[i]);
      |                         ~~~~~^~~~~~~~~~~~~~
long_mansion.cpp:31:14: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
   31 |         scanf("%i",&sz);
      |         ~~~~~^~~~~~~~~~
long_mansion.cpp:35:18: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
   35 |             scanf("%i",&val);
      |             ~~~~~^~~~~~~~~~~
long_mansion.cpp:61:10: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
   61 |     scanf("%i",&q);
      |     ~~~~~^~~~~~~~~
long_mansion.cpp:66:14: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
   66 |         scanf("%i%i",&le,&ri);
      |         ~~~~~^~~~~~~~~~~~~~~~