#include using namespace std; #include #define elif else if #define ll long long using mint=atcoder::modint998244353; using S=pair; mint pow11[1<<18]; mint pow2[1<<18]; S node[19][1<<18]; int last_update[19][1<<18]; int lazy[1<<19]; int n,N,Time; S merge(S L,S R){ return {L.first*pow11[R.second]+R.first*pow2[L.second],L.second+R.second}; } void build(){ for(int i=0;i<=n;i++){ for(int j=0;j>=1; } Time+=1; } S get(int i,int j){ //cout<<'?'<<' '<>i]){ return node[i][j]; } node[i][j]=merge(get(i-1,j),get(i-1,j^(1<<(i-1)))); last_update[i][j]=lazy[(j+N)>>i]; return node[i][j]; } S E={0,0}; S query(int L,int R,int X){ S res=E; //cout<<'!'<<' '<>i)&1)&&(L+(1<=0;--i){ if(L+(1<>n; N=1<>s; for(int i=0;i>q; for(int tc=0;tc>t; if(t==1){ cin>>x>>y; update(x,{y,1}); } else{ cin>>L>>R>>X; cout<