#include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #define popcount __builtin_popcount using namespace std; typedef long long int ll; typedef pair P; const ll MOD=998244353; void FWT(vector &v){ int m=v.size(); for(int i=1; i>n; vector c(1<>c[i]; } FWT(c); ll ans=0; for(int i=0; i<(1<>l>>h; if(c[i]>0) ans+=c[i]*h; else ans+=c[i]*l; } ans%=MOD; for(int i=0; i