随笔分类 -  PAT

摘要:Notice that the number 123456789 is a 9-digit number consisting exactly the numbers from 1 to 9, with no duplication. Double it we will obtain 2469135 阅读全文
posted @ 2019-03-08 20:26 Pure_Java 阅读(249) 评论(0) 推荐(0)
摘要:A Digital Library contains millions of books, stored according to their titles, authors, key words of their abstracts, publishers, and published years 阅读全文
posted @ 2019-03-08 20:24 Pure_Java 阅读(217) 评论(0) 推荐(0)
摘要:Suppose that all the keys in a binary tree are distinct positive integers. Given the postorder and inorder traversal sequences, you are supposed to ou 阅读全文
posted @ 2019-03-08 20:23 Pure_Java 阅读(235) 评论(0) 推荐(0)
摘要:A number that will be the same when it is written forwards or backwards is known as a Palindromic Number. For example, 1234321 is a palindromic number 阅读全文
posted @ 2019-03-08 20:22 Pure_Java 阅读(175) 评论(0) 推荐(0)
摘要:A reversible prime in any number system is a prime whose "reverse" in that number system is also a prime. For example in the decimal system 73 is a re 阅读全文
posted @ 2019-03-08 20:21 Pure_Java 阅读(267) 评论(0) 推荐(0)
摘要:It is vitally important to have all the cities connected by highways in a war. If a city is occupied by the enemy, all the highways from/toward that c 阅读全文
posted @ 2019-03-08 20:20 Pure_Java 阅读(308) 评论(0) 推荐(0)
摘要:To evaluate the performance of our first year CS majored students, we consider their grades of three courses only: C - C Programming Language, M - Mat 阅读全文
posted @ 2019-03-08 20:18 Pure_Java 阅读(448) 评论(0) 推荐(0)
摘要:With the 2010 FIFA World Cup running, football fans the world over were becoming increasingly excited as the best players from the best teams doing ba 阅读全文
posted @ 2019-03-08 20:16 Pure_Java 阅读(149) 评论(0) 推荐(0)
摘要:Given a pair of positive integers, for example, 6 and 110, can this equation 6 = 110 be true? The answer is yes, if 6 is a decimal number and 110 is a 阅读全文
posted @ 2019-03-08 20:15 Pure_Java 阅读(341) 评论(0) 推荐(0)
摘要:This time, you are supposed to find A×BA\times BA×B where AAA and BBB are two polynomials. Input Specification: Each input file contains one test case 阅读全文
posted @ 2019-03-08 20:13 Pure_Java 阅读(333) 评论(0) 推荐(0)
摘要: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 elev 阅读全文
posted @ 2019-03-08 20:12 Pure_Java 阅读(166) 评论(0) 推荐(0)
摘要:1007 Maximum Subsequence Sum (25 分) Given a sequence of K integers { N​1​​, N​2​​, ..., N​K​​ }. A continuous subsequence is defined to be { N​i​​, N​ 阅读全文
posted @ 2019-03-08 20:07 Pure_Java 阅读(318) 评论(0) 推荐(0)
摘要:At the beginning of every day, the first person who signs in the computer room will unlock the door, and the last one who signs out will lock the door 阅读全文
posted @ 2019-03-08 20:06 Pure_Java 阅读(289) 评论(0) 推荐(0)
摘要:Given a non-negative integer N, your task is to compute the sum of all the digits of N, and output every digit of the sum in English. Input Specificat 阅读全文
posted @ 2019-03-08 20:04 Pure_Java 阅读(243) 评论(0) 推荐(0)
摘要:A family hierarchy is usually presented by a pedigree tree. Your job is to count those family members who have no child. Input Specification: Each inp 阅读全文
posted @ 2019-03-08 20:03 Pure_Java 阅读(288) 评论(0) 推荐(0)
摘要:As an emergency rescue team leader of a city, you are given a special map of your country. The map shows several scattered cities connected by some ro 阅读全文
posted @ 2019-03-08 20:02 Pure_Java 阅读(721) 评论(0) 推荐(0)
摘要:This time, you are supposed to find A+BA+BA+B where AAA and BBB are two polynomials. Input Specification: Each input file contains one test case. Each 阅读全文
posted @ 2019-03-08 20:00 Pure_Java 阅读(596) 评论(0) 推荐(0)
摘要:1001 A+B Format (20 分) Calculate a+b and output the sum in standard format -- that is, the digits must be separated into groups of three by commas (un 阅读全文
posted @ 2019-03-08 19:57 Pure_Java 阅读(439) 评论(1) 推荐(0)