摘要: /*简单dp加单调队列*/ #include<stdio.h>#include<string.h>int N,M,D,S;int ac[6000];int dp[2][6000];int qu[6000];void fc(){ int i,k,j,l,cnt; for(i=0;i<M;i++) { cnt=i%2; qu[0]=1; k=0;j=0; for(l=1;l<=N;l++) { while(k<=j&&dp[cnt][qu[j]]<=dp[cnt][l]) ... 阅读全文
posted @ 2012-07-25 12:02 zhuiy 阅读(133) 评论(0) 推荐(0)