省选动态规划专题
开题顺序: \(ARJB\)
\(A\) luogu P4141 消失之物
-
点击查看代码
int w[2001],v[2001],f[2001],g[2001]; int main() { int n,m,i,j; cin>>n>>m; f[0]=1; for(i=1;i<=n;i++) { cin>>w[i]; } for(i=1;i<=n;i++) { for(j=m;j>=w[i];j--) { f[j]=(f[j]+f[j-w[i]])%10; } } for(i=1;i<=n;i++) { g[0]=1; for(j=1;j<=m;j++) { if(j-w[i]>=0) { g[j]=(f[j]-g[j-w[i]]+10)%10; } else { g[j]=f[j]%10; } cout<<g[j]; } cout<<endl; } return 0; }
\(B\) luogu P2371 [国家集训队] 墨墨的等式
\(C\) luogu P8392 [BalticOI 2022 Day1] Uplifting Excursion
\(D\) luogu P4322 [JSOI2016] 最佳团体
\(E\) luogu P3592 [POI2015] MYJ
\(F\) [AGC026D] Histogram Coloring
\(G\) CF1372E Omkar and Last Floor
\(H\) luogu P6563 [SBCOI2020] 一直在你身旁
\(I\) CF868F Yet Another Minimization Problem
\(J\) luogu P3648 [APIO2014] 序列分割
\(K\) CF1175G Yet Another Partiton Problem
\(L\) luogu P4383 [八省联考 2018] 林克卡特树
\(M\) CF321E Ciel and Gondolas
\(N\) [ABC305Ex] Shojin
\(O\) CF713C Sonya and Problem Wihtout a Legend
- 多倍经验: CF13C Sequence