正文
增加 2 行删除 2 行
58 行未改动59606162636465666718 行未改动868788899091929394127 行未改动全部展开58 行未改动template<typename G> inline void read(G &x) {x=0;G f=1;char ch=getchar();while((ch<'0'||ch>'9')&&ch!='-') ch=getchar();if(ch=='-') f=-1,ch=getchar();while(ch>='0'&&ch<='9') {x=x*10+(ch^48);ch=getchar();}x*=f;}const int MAXN=(1<<22)+5;int d[30];void update(int x,int z) {for(int i=x;i<30;i+=(i&-i)) d[i]=min(d[i],z);}int query(int x) {int res=INT_MAX;for(int i=x;i;i-=(i&-i)) res=min(res,d[i]);18 行未改动}int n,k,f[MAXN],las[MAXN],as[MAXN],lis[MAXN],ans[30],nxt[30];bool g[30];vector<int> v[30];signed main() {// freopen("passports.in","r",stdin);// freopen("passports.out","w",stdout);read(n),read(k);for(int i=1;i<=n;++i) {127 行未改动全部展开58 行未改动59606162636465666718 行未改动868788899091929394127 行未改动全部展开58 行未改动template<typename G> inline void read(G &x) {x=0;G f=1;char ch=getchar();while((ch<'0'||ch>'9')&&ch!='-') ch=getchar();if(ch=='-') f=-1,ch=getchar();while(ch>='0'&&ch<='9') {x=x*10+(ch^48);ch=getchar();}x*=f;}const int MAXN=(1<<22)+5;int d[30];void update(int x,int z) {for(int i=x;i<30;i+=(i&-i)) d[i]=min(d[i],z);}int query(int x) {int res=INT_MAX;for(int i=x;i;i-=(i&-i)) res=min(res,d[i]);18 行未改动}int n,k,f[MAXN],las[MAXN],as[MAXN],lis[MAXN],ans[30],nxt[30];bool g[30];vector<int> v[30];signed main() {// freopen("passports.in","r",stdin);// freopen("passports.out","w",stdout);read(n),read(k);for(int i=1;i<=n;++i) {127 行未改动全部展开