//// main.cpp// circleQueue//// Created by zhou on 14-6-19.// Copyright (c) 2014年 zhou. All rights reserved.//#define Max 50typedef struct ...
分类:
其他好文 时间:
2014-06-28 18:54:47
阅读次数:
171
http://poj.org/problem?id=1185dp[i][j][k]表示第i行状态为k,第i-1行为j;状态转移方程dp[i][j][k]=max(dp[i][j][k],dp[i-1][j][k]+c[k]); 1 #include 2 #include 3 #include ...
分类:
其他好文 时间:
2014-06-28 17:09:38
阅读次数:
206
【题目描述】对于从1到N (1 2 #include 3 #include 4 #include 5 #include 6 const int Max=1000000; 7 using namespace std; 8 long long cnt[Max],n; 9 int main()1...
分类:
其他好文 时间:
2014-06-28 16:48:53
阅读次数:
148
很久以前做的树形DP题,今天再遇到时,竟然不会了,所以写写。。设数组:prf[MAX][MAX],cost[MAX],sum[MAX]。分别表示,在第i个结点为根的子树内的情况下,若有j个用户申请看电视,所能得到的最大费用。cost表示传送到i点时所花的费用,而sum表示当前结点为根的子树内已访问的...
分类:
其他好文 时间:
2014-06-28 14:28:23
阅读次数:
293
基础数据结构: struct A { int a; int b; int c; int d; int e; int f; int g; };初始化次数:const int MAX_L...
分类:
其他好文 时间:
2014-06-21 00:17:14
阅读次数:
166
1 #include 2 #include 3 using namespace std; 4 5 const int MAX=105; 6 7 bool vis[MAX][MAX]; 8 char maze[MAX][MAX]; 9 int n,m;10 int dir[8][2]={0,...
分类:
其他好文 时间:
2014-06-21 00:14:01
阅读次数:
275
>_____<:头文件参见:http://www.cnblogs.com/zjutlitao/p/3733164.html 1 #include "stdafx.h" 2 #include "resourse.h" 3 4 #define MAX_LOADSTRING 100 5 6...
.catelistdlddulliimg{width:expression(this.width>228?'228px':true);max-width:228px;height:expression(this.height>160?'160px':true);max-height:160px;}解...
分类:
其他好文 时间:
2014-06-20 17:50:42
阅读次数:
155
今天使用MongoDB的C++驱动,在编译连接的时候一直出现错误,显示的string_data.h下93行max宏的问题,可视其本身并不是调用max宏,而是调用std::numeric_limits::max这样就是产生错误,通过搜索发现解决方法(参考网址:http://blog.chinaunix...
分类:
数据库 时间:
2014-06-20 17:08:50
阅读次数:
273
母函数简单题 1 #include 2 #include 3 using namespace std; 4 5 const int MAX=130000; 6 int c1[MAX],c2[MAX]; 7 8 struct { 9 int val,num;10 }thing[55];...
分类:
其他好文 时间:
2014-06-20 16:07:13
阅读次数:
164