摘要: 题目描述 Now, here is a fuction: F(x) = 6 * x^7+8x^6+7x^3+5x^2-yx (0 #include#include#includeusing namespace std;double f_d(double res){ return res*res*res*res *res*res*42 + res*res*res*res*res*48 +... 阅读全文
posted @ 2016-04-18 20:21 Pic 阅读(148) 评论(0) 推荐(0) 编辑
摘要: 题目描述 Now,given the equation 8x^4 + 7x^3 + 2x^2 + 3x + 6 == Y,can you find its solution between 0 and 100;Now please try your lucky. Input The first line of the input contains an integer T(1#include... 阅读全文
posted @ 2016-04-18 20:11 Pic 阅读(137) 评论(0) 推荐(0) 编辑
摘要: 题目描述 FJ is surveying his herd to find the most average cow. He wants to know how much milk this ‘median’ cow gives: half of the cows give as much or more than the median; half give as much or less. ... 阅读全文
posted @ 2016-04-04 21:33 Pic 阅读(173) 评论(0) 推荐(0) 编辑
摘要: 题目描述 Problem Description The highest building in our city has only one elevator. A request list is made up with N positive numbers. The numbers denote at which floors the elevator will stop, in spec... 阅读全文
posted @ 2016-04-04 21:21 Pic 阅读(119) 评论(0) 推荐(0) 编辑
摘要: 题目描述 Before bridges were common, ferries were used to transport cars across rivers. River ferries, unlike their larger cousins, run on a guide line and are powered by the river’s current. Cars drive ... 阅读全文
posted @ 2016-03-29 23:40 Pic 阅读(230) 评论(0) 推荐(0) 编辑
摘要: 题目描述 There is a pile of n wooden sticks. The length and weight of each stick are known in advance. The sticks are to be processed by a woodworking machine in one by one fashion. It needs some time, c... 阅读全文
posted @ 2016-03-29 00:50 Pic 阅读(159) 评论(0) 推荐(0) 编辑
摘要: 题目描述 The famous ACM (Advanced Computer Maker) Company has rented a floor of a building whose shape is in the following figure. The floor has 200 rooms each on the north side and south side along t... 阅读全文
posted @ 2016-03-26 19:57 Pic 阅读(179) 评论(0) 推荐(0) 编辑
摘要: 题目描述 Here is a famous story in Chinese history. “That was about 2300 years ago. General Tian Ji was a high official in the country Qi. He likes to play horse racing with the king and others.” “Both... 阅读全文
posted @ 2016-03-20 23:22 Pic 阅读(197) 评论(0) 推荐(0) 编辑
摘要: problemE 题目描述 “今年暑假不AC?” “是的。” “那你干什么呢?” “看世界杯呀,笨蛋!” “@#$%^&*%…” 确实如此,世界杯来了,球迷的节日也来了,估计很多ACMer也会抛开电脑,奔向电视了。 作 为球迷,一定想看尽量多的完整的比赛,当然,作为新时代的好青年,你一定还会看一些其它的节目,比如新闻联播(永远不要忘记关心国家大事)、非常6+7、 超级女生,以及王小... 阅读全文
posted @ 2016-03-20 22:32 Pic 阅读(166) 评论(0) 推荐(0) 编辑
摘要: 这些函数由于设计的时候比较淳朴,并没有做任何的越界检测,主要容易”被溢出”,只需要多设点检查边界,即安全。 函数 严重性 解决方案 gets 最危险 使用 fgets(buf, size, stdin)。这几乎总是一个大问题! strcpy 很危险 改为使用 strncpy。 strcat 很危险 改为使用 strncat。 ... 阅读全文
posted @ 2016-03-14 23:21 Pic 阅读(554) 评论(0) 推荐(0) 编辑