摘要: F - Laurenty and Shop Time Limit:1000MS Memory Limit:262144KB 64bit IO Format:%I64d & %I64u Submit Status Practice CodeForces 586B F - Laurenty and Sh 阅读全文
posted @ 2016-07-15 22:42 超级学渣渣 阅读(260) 评论(0) 推荐(0) 编辑
摘要: const int MAXN = 1010; int n; int a[MAXN]; int dp[MAXN]; /*dp[i]表示以i结尾的子序列中LIS的长度。然后我用dp[j](0a[j]的时候,我们需要进行判断,是否将a[i]加入到dp[j]当中。为了保证我们每次加入都是得到一个最优的LIS,有两点需要注意:第一,每一次,a[i]都应当加入最大的那个dp[j],保证局部性质最优,也就是我... 阅读全文
posted @ 2016-07-15 14:33 超级学渣渣 阅读(363) 评论(0) 推荐(0) 编辑
摘要: #include #include #include #include using namespace std; int dp[20]; const int inf=0x7fffffff; int a[7]={2,1,3,4,8,5,9}; const int maxn=500005; int main() { fill(dp,dp+7... 阅读全文
posted @ 2016-07-15 14:33 超级学渣渣 阅读(168) 评论(0) 推荐(0) 编辑
摘要: Constructing Roads In JGShining's Kingdom Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 22338 A 阅读全文
posted @ 2016-07-15 14:29 超级学渣渣 阅读(825) 评论(0) 推荐(0) 编辑
摘要: sublime text是一个非常神奇到编辑器,对于我这种小白来说,感觉比vim好用,但是如果用sublime自带到编译环境到话,是没法向程序汇总输入数据的,所以要自己新建编译命令 然后保存为新的编译命令并且使用之就可以了。 阅读全文
posted @ 2016-07-15 13:28 超级学渣渣 阅读(166) 评论(0) 推荐(0) 编辑