![](https://img-blog.csdnimg.cn/20201014180756925.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
ACM&DP
Akira_H
努力做到更好!!!
展开
-
【dp】+免费馅饼
题意:略(注意时间不一定按从小到大的顺序)。思路:用dp数组倒着推。#include#include#include#include#include#include#include#include#include#include#include#include#include#include#include#define fuck(x) cout<<"["<<原创 2016-03-18 20:35:50 · 234 阅读 · 0 评论 -
51nodLearning-dp入门之循环数组的最大子段和
思路:51nod上很详细,我就不讲了直接上代码:/*我的断点就去最后的那个,方便求普通的最大子段和#include #include #include #define FIN freopen("input.txt","r",stdin)using namespace std;typedef long long ll;const int MAX=50005;int n;ll原创 2016-04-23 19:58:04 · 216 阅读 · 0 评论 -
51nod-dp入门-最大子矩阵和
思路见51nod。代码附上:#include #include using namespace std;typedef long long ll;const int MAX=510;int m,n;ll a[MAX][MAX],c[MAX];int main(){ while(~scanf("%d%d",&m,&n)){ for(int i=0;i<n;i++){原创 2016-04-23 20:00:45 · 612 阅读 · 0 评论 -
51nod更难得矩阵取数
思路见51nodLearning。代码:#include #include #include #define FIN freopen("input.txt","r",stdin)using namespace std;const int MAX=205;int N,M;int a[MAX][MAX],dp[2*MAX][MAX][MAX];int main(){ //FIN原创 2016-04-24 21:56:03 · 231 阅读 · 0 评论