摘要: 对于交题目OJ给的评判是TLE、RE、MLE是极其陌生的、 针对问题提出我在这方面的问题 (1) 对于MLE一般是数组开大的缘故,但是我在修改程序的时候,一个变量在两个位置出现过我却只修改一次,必须指出这是我对自己程序上下贯通不严谨的问题 (2) RE的话是我对题意的错解或者是完全没看清题,这又是我 阅读全文
posted @ 2016-03-03 21:34 我不萌、我要高冷 阅读(121) 评论(0) 推荐(0)
摘要: 1 #include<cstdio> 2 #include<cmath> 3 #include<iostream> 4 #include<cstring> 5 const int qq=2000+50; 6 int v[qq],w[qq],dp[qq]; 7 using namespace std; 阅读全文
posted @ 2016-03-03 21:26 我不萌、我要高冷 阅读(500) 评论(0) 推荐(0)
摘要: 转载自:http://www.cnblogs.com/jbelial/articles/2116074.html P01: 01背包问题 题目 有N件物品和一个容量为V的背包。第i件物品的费用是c[i],价值是w[i]。求解将哪些物品装入背包可使这些物品的费用总和不超过背包容量,且价值总和最大。 基 阅读全文
posted @ 2016-03-03 21:12 我不萌、我要高冷 阅读(277) 评论(0) 推荐(0)
摘要: Description In mathematics, the nth harmonic number is the sum of the reciprocals of the first n natural numbers: In this problem, you are given n, yo 阅读全文
posted @ 2016-03-03 19:56 我不萌、我要高冷 阅读(442) 评论(0) 推荐(0)