ll@n,@q,@a[n],c[],@b[q]; rep(i,n){ c[i]=i; } rep(j,q){ ll w=ll_inf; rep(i,n){ w