会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
sola94
纵有疾风起 人生不言弃。
博客园
首页
新随笔
联系
订阅
管理
上一页
1
2
3
4
5
6
7
···
22
下一页
2015年8月1日
poj 2342 Anniversary party (树形dp)
摘要: #include#include#include#includeusing namespace std;int fa[7000];int dp[7000][5];int vis[7000];int n;void dfs(int rt){ int i,j,k; vis[rt]=1; ...
阅读全文
posted @ 2015-08-01 20:35 sola94
阅读(81)
评论(0)
推荐(0)
2015年7月31日
POJ 1611 The Suspects (并查集)
摘要: #include#include#include#include#includeusing namespace std;int vis_tuan[500+10];int vis[30000+10];int mat[30000+10][510];int fa[30000+10];int ans;int...
阅读全文
posted @ 2015-07-31 19:37 sola94
阅读(93)
评论(0)
推荐(0)
poj 2236 Wireless Network(并查集)
摘要: #include#include#include#includeusing namespace std;struct Node{ double x,y;};Node node[1100];int vis[1100];double mat[1005][1005];int fa[1005];int...
阅读全文
posted @ 2015-07-31 19:36 sola94
阅读(104)
评论(0)
推荐(0)
hdu 3591 The trouble of Xiaoqian(多重背包)
摘要: #include#include#include#include#includeusing namespace std;int v[200],c[200];int dp[30000];int main(){ int n,t; int i,j,k; int cas=1; whi...
阅读全文
posted @ 2015-07-31 01:45 sola94
阅读(150)
评论(0)
推荐(0)
2015年7月30日
hdu 2079 选课时间(母函数)
摘要: 母函数#include#include#include#include#includeusing namespace std;int dp[50];struct Clas{ int v,c;};Clas cla[50];int c1[500000];int c2[500000];int t,n...
阅读全文
posted @ 2015-07-30 16:53 sola94
阅读(164)
评论(0)
推荐(0)
hdu 5326 Work (dp 记忆化搜索)
摘要: #include#include#includeusing namespace std;int mat[200][200];int dp[200];int vis[200];int n;int dfs(int x){ //printf("%d........\n",x); int i,j...
阅读全文
posted @ 2015-07-30 11:20 sola94
阅读(128)
评论(0)
推荐(0)
CodeForces 315B Sereja and Array (水)
摘要: #include#include#include#include#includeusing namespace std;int a[300000];int main(){ int n,m; int i,j,k; int op,num; scanf("%d%d",&n,&m);...
阅读全文
posted @ 2015-07-30 00:16 sola94
阅读(127)
评论(0)
推荐(0)
CodeForces 315A Sereja and Bottles(水)
摘要: #include#include#include#include#includeusing namespace std;int a[200],b[200];int vis[200];int main(){ int n; int i,j,k; while(scanf("%d",&n)!=EOF)...
阅读全文
posted @ 2015-07-30 00:15 sola94
阅读(170)
评论(0)
推荐(0)
2015年7月29日
hdu 2844 Coins(dp 多重背包)
摘要: #include#include#include#includeusing namespace std;struct Coin{ int v,c;};Coin coin[200];int dp[100000+100];int main(){ int t,n,m; int p,h,c; ...
阅读全文
posted @ 2015-07-29 15:15 sola94
阅读(117)
评论(0)
推荐(0)
hdu 2191 悼念512汶川大地震遇难同胞——珍惜现在,感恩生活 (dp 多重背包)
摘要: 转化为01背包#include#include#include#includeusing namespace std;struct Rice{ int v,w,c;};Rice r[120];int dp[50000];int main(){ int t,n,m; int p,h,...
阅读全文
posted @ 2015-07-29 13:10 sola94
阅读(186)
评论(0)
推荐(0)
上一页
1
2
3
4
5
6
7
···
22
下一页
公告