horses.cpp: In member function 'void tree::upd(int, int)':
horses.cpp:22:22: warning: declaration of 'x' shadows a global declaration [-Wshadow]
22 | void upd(int i, int x){
| ~~~~^
horses.cpp:7:13: note: shadowed declaration is here
7 | vector<int> x, y;
| ^
horses.cpp: In constructor 'FT::FT(int)':
horses.cpp:41:9: warning: declaration of 'n' shadows a member of 'FT' [-Wshadow]
41 | FT(int n): n(n), ft(n + 1){}
| ~~~~^
horses.cpp:39:6: note: shadowed declaration is here
39 | int n;
| ^
horses.cpp:39:6: warning: 'FT::n' will be initialized after [-Wreorder]
horses.cpp:38:13: warning: 'std::vector<long long int> FT::ft' [-Wreorder]
38 | vector<ll> ft;
| ^~
horses.cpp:41:2: warning: when initialized here [-Wreorder]
41 | FT(int n): n(n), ft(n + 1){}
| ^~
horses.cpp: In constructor 'FT::FT(int)':
horses.cpp:41:9: warning: declaration of 'n' shadows a member of 'FT' [-Wshadow]
41 | FT(int n): n(n), ft(n + 1){}
| ~~~~^
horses.cpp:39:6: note: shadowed declaration is here
39 | int n;
| ^
horses.cpp: In constructor 'FT::FT(int)':
horses.cpp:41:9: warning: declaration of 'n' shadows a member of 'FT' [-Wshadow]
41 | FT(int n): n(n), ft(n + 1){}
| ~~~~^
horses.cpp:39:6: note: shadowed declaration is here
39 | int n;
| ^
horses.cpp: In member function 'void FT::upd(int, int)':
horses.cpp:42:22: warning: declaration of 'x' shadows a global declaration [-Wshadow]
42 | void upd(int i, int x){
| ~~~~^
horses.cpp:7:13: note: shadowed declaration is here
7 | vector<int> x, y;
| ^
horses.cpp: In function 'll pwr(ll, ll)':
horses.cpp:56:17: warning: declaration of 'y' shadows a global declaration [-Wshadow]
56 | ll pwr(ll x, ll y){
| ~~~^
horses.cpp:7:16: note: shadowed declaration is here
7 | vector<int> x, y;
| ^
horses.cpp:56:11: warning: declaration of 'x' shadows a global declaration [-Wshadow]
56 | ll pwr(ll x, ll y){
| ~~~^
horses.cpp:7:13: note: shadowed declaration is here
7 | vector<int> x, y;
| ^
horses.cpp: In function 'int solve()':
horses.cpp:91:19: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<std::pair<int, int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
91 | for(int i = 0; i < a.size(); i++){
| ~~^~~~~~~~~~
horses.cpp:95:24: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<std::pair<int, int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
95 | for(int j = i + 1; j < a.size(); j++){
| ~~^~~~~~~~~~
horses.cpp:97:7: warning: conversion from 'll' {aka 'long long int'} to 'double' may change value [-Wconversion]
97 | if(pre > 1e9){
| ^~~
horses.cpp:104:29: warning: conversion from 'll' {aka 'long long int'} to 'int' may change value [-Wconversion]
104 | return cur * a[i].second % mod;
| ~~~~~~~~~~~~~~~~~~^~~~~
horses.cpp: In function 'int updateX(int, int)':
horses.cpp:132:45: warning: conversion from 'll' {aka 'long long int'} to 'int' may change value [-Wconversion]
132 | ft.upd(pos + 1, pwr(x[pos], mod - 2) * val % mod);
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~