随笔分类 -  解题报告

摘要:Problem Description 把一个偶数拆成两个不同素数的和,有几种拆法呢? Input 输入包含一些正的偶数,其值不会超过10000,个数不会超过500,若遇0,则结束。 Output 对应每个偶数,输出其拆成不同素数的个数,每个结果占一行。 Sample Input 30 26 0 3 阅读全文
posted @ 2016-05-19 23:19 Not-Bad 阅读(193) 评论(0) 推荐(0)
摘要:http://poj.org/problem?id=2140 Description The cows in farmer John's herd are numbered and branded with consecutive integers from 1 to N (1 <= N <= 10 阅读全文
posted @ 2016-05-19 22:48 Not-Bad 阅读(219) 评论(0) 推荐(0)
摘要:The word "search engine" may not be strange to you. Generally speaking, a search engine searches the web pages available in the Internet, extracts and 阅读全文
posted @ 2016-05-17 10:01 Not-Bad 阅读(647) 评论(0) 推荐(0)
摘要:In this problem, we consider a simple programming language that has only declarations of one-dimensional integer arrays and assignment statements. The 阅读全文
posted @ 2016-05-13 23:15 Not-Bad 阅读(295) 评论(0) 推荐(0)
摘要:Like Mr. Lamb, librarians have their problems with borrowers too. People don't put books back where they should. Instead, returned books are kept at t 阅读全文
posted @ 2016-05-10 22:33 Not-Bad 阅读(265) 评论(0) 推荐(0)
摘要:The only printer in the computer science students' union is experiencing an extremely heavy workload. Sometimes there are a hundred jobs in the printe 阅读全文
posted @ 2016-05-10 20:59 Not-Bad 阅读(262) 评论(0) 推荐(0)
摘要:给出平面上N(N<=1000)个点。问是否可以找到一条竖线,使得所有点左右对称,如图所示: 则左边的图形有对称轴,右边没有。 Sample Input 3 5 -2 5 0 0 6 5 4 0 2 3 4 2 3 0 4 4 0 0 0 4 5 14 6 10 5 10 6 14 Sample Ou 阅读全文
posted @ 2016-05-10 19:14 Not-Bad 阅读(288) 评论(0) 推荐(0)
摘要:Compound Words You are to find all the two-word compound words in a dictionary. A two-word compound word is a word in the dictionary that is theconcat 阅读全文
posted @ 2016-05-10 12:58 Not-Bad 阅读(217) 评论(0) 推荐(0)
摘要:Foreign Exchange Your non-profit organization (iCORE - international Confederation of Revolver Enthusiasts) coordinates a very successful foreign stud 阅读全文
posted @ 2016-05-10 12:31 Not-Bad 阅读(201) 评论(0) 推荐(0)
摘要:Given is an ordered deck of n cards numbered 1 to n with card 1 at the top and card n at the bottom. The following operation is performed as long as t 阅读全文
posted @ 2016-05-05 09:47 Not-Bad 阅读(213) 评论(0) 推荐(0)
摘要:Ducci Sequence Description A Ducci sequence is a sequence of n-tuples of integers. Given an n-tuple of integers (a1, a2, ... , an), the next n-tuple i 阅读全文
posted @ 2016-05-05 08:16 Not-Bad 阅读(253) 评论(0) 推荐(0)
摘要:Description You are working in a team that writes Incredibly Customizable Programming Codewriter (ICPC) which is basically a text editor with bells an 阅读全文
posted @ 2016-05-04 23:43 Not-Bad 阅读(295) 评论(0) 推荐(0)
摘要:Samuel F. B. Morse is best known for the coding scheme that carries his name. Morse code is still used in international radio communication. The codin 阅读全文
posted @ 2016-04-28 09:40 Not-Bad 阅读(438) 评论(0) 推荐(0)
摘要:Description To enable homebuyers to estimate the cost of flood insurance, a real-estate firm provides clients with the elevation of each 10-meter by 1 阅读全文
posted @ 2016-04-25 20:45 Not-Bad 阅读(196) 评论(0) 推荐(0)
摘要:We have a machine for painting cubes. It is supplied with three different colors: blue, red and green. Each face of the cube gets one of these colors. 阅读全文
posted @ 2016-04-18 20:12 Not-Bad 阅读(223) 评论(0) 推荐(0)
摘要:A children's board game consists of a square array of dots that contains lines connecting some of the pairs of adjacent dots. One part of the game req 阅读全文
posted @ 2016-04-18 19:11 Not-Bad 阅读(199) 评论(0) 推荐(0)
摘要:输入一个n行m列的数据库(1<=n<=10000,1<=m<=10),是否存在两个不同行r1,r2和两个不同列c1,c2,使得这两行和这两行相同(即(r1,c1)和(r2,c1)相同, (r1,c2)和(r2,c2)相同)。例如,对于如图所示的数据库,第2、3行和第2、3列满足要求 How to c 阅读全文
posted @ 2016-04-11 20:23 Not-Bad 阅读(348) 评论(0) 推荐(0)
摘要:Problem Description Xiangqi is one of the most popular two-player board games in China. The game represents a battle between two armies with the goal 阅读全文
posted @ 2016-04-09 19:53 Not-Bad 阅读(266) 评论(0) 推荐(0)
摘要:Description For an electronic mail application you are to describe the SMTP-based communication that takes place between pairs of MTAs. The sender's U 阅读全文
posted @ 2016-04-04 10:07 Not-Bad 阅读(440) 评论(0) 推荐(0)
摘要:题意:给出一张俯视图。给出N个建筑物的左下标,长度,宽度,高度。现在求,从南面看,能看到那些建筑? Sample Input Sample Output 离散化 基本思想就是在众多可能的情况中“只考虑我需要用的值”。 eg.1 给定平面上n个点的坐标,求能够覆盖所有这些点的最小矩形面积。这个问题难就 阅读全文
posted @ 2016-03-28 20:20 Not-Bad 阅读(957) 评论(0) 推荐(0)