#include using namespace std; int main(){ int N,Q,x; scanf("%d%d",&N,&Q); long long a[N],b[N]; for(int i=N-1;i>=0;--i){ a[i]=1; for(int j=i*2+1;j