随笔分类 -  PAT 甲级

摘要:A supply chain is a network of retailers(零售商), distributors(经销商), and suppliers(供应商)-- everyone involved in moving a product from supplier to customer 阅读全文
posted @ 2018-07-10 21:15 王清河 阅读(134) 评论(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 @ 2018-06-24 22:36 王清河 阅读(261) 评论(0) 推荐(0) 编辑
摘要:People often have a preference among synonyms of the same word. For example, some may prefer "the police", while others may prefer "the cops". Analyzi 阅读全文
posted @ 2018-06-08 12:55 王清河 阅读(174) 评论(0) 推荐(0) 编辑
摘要:Behind the scenes in the computer's memory, color is always talked about as a series of 24 bits of information for each pixel. In an image, the color 阅读全文
posted @ 2018-06-08 11:48 王清河 阅读(153) 评论(0) 推荐(0) 编辑
摘要:If a machine can save only 3 significant digits, the float numbers 12300 and 12358.9 are considered equal since they are both saved as 0.123*105 with 阅读全文
posted @ 2018-04-24 20:29 王清河 阅读(143) 评论(0) 推荐(0) 编辑
摘要:Given two sets of integers, the similarity of the sets is defined to be Nc/Nt*100%, where Nc is the number of distinct common numbers shared by the tw 阅读全文
posted @ 2018-04-23 11:03 王清河 阅读(90) 评论(0) 推荐(0) 编辑
摘要:Zhejiang University has 40000 students and provides 2500 courses. Now given the registered course list of each student, you are supposed to output the 阅读全文
posted @ 2018-04-22 19:52 王清河 阅读(102) 评论(0) 推荐(0) 编辑
摘要:Zhejiang University has 40000 students and provides 2500 courses. Now given the student name lists of all the courses, you are supposed to output the 阅读全文
posted @ 2018-04-22 18:51 王清河 阅读(157) 评论(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 @ 2018-04-22 14:53 王清河 阅读(332) 评论(0) 推荐(0) 编辑
摘要: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 @ 2018-04-21 20:28 王清河 阅读(138) 评论(0) 推荐(0) 编辑
摘要:Among all the factors of a positive integer N, there may exist several consecutive numbers. For example, 630 can be factored as 3*5*6*7, where 5, 6, a 阅读全文
posted @ 2018-04-18 20:13 王清河 阅读(104) 评论(0) 推荐(0) 编辑
摘要:The task of this problem is simple: insert a sequence of distinct positive integers into a hash table, and output the positions of the input numbers. 阅读全文
posted @ 2018-04-18 19:45 王清河 阅读(108) 评论(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 @ 2018-04-10 19:22 王清河 阅读(113) 评论(0) 推荐(0) 编辑
摘要:Given a sequence of positive integers and another positive integer p. The sequence is said to be a "perfect sequence" if M <= m * p where M and m are 阅读全文
posted @ 2018-03-29 12:28 王清河 阅读(161) 评论(0) 推荐(0) 编辑
摘要:Given a collection of number segments, you are supposed to recover the smallest number from them. For example, given {32, 321, 3214, 0229, 87}, we can 阅读全文
posted @ 2018-03-29 11:54 王清河 阅读(102) 评论(0) 推荐(0) 编辑
摘要:Given any permutation of the numbers {0, 1, 2,..., N-1}, it is easy to sort them in increasing order. But what if Swap(0, *) is the ONLY operation tha 阅读全文
posted @ 2018-03-28 15:01 王清河 阅读(96) 评论(0) 推荐(0) 编辑
摘要:The magic shop in Mars is offering some magic coupons. Each coupon has an integer N printed on it, meaning that when you use this coupon with a produc 阅读全文
posted @ 2018-03-28 10:44 王清河 阅读(118) 评论(0) 推荐(0) 编辑
摘要:With highways available, driving a car from Hangzhou to any other city is easy. But since the tank capacity of a car is limited, we have to find gas s 阅读全文
posted @ 2018-03-27 15:48 王清河 阅读(137) 评论(0) 推荐(0) 编辑
摘要:Mooncake is a Chinese bakery product traditionally eaten during the Mid-Autumn Festival. Many types of fillings and crusts can be found in traditional 阅读全文
posted @ 2018-03-27 09:20 王清河 阅读(169) 评论(0) 推荐(0) 编辑
摘要:Eva loves to collect coins from all over the universe, including some other planets like Mars. One day she visited a universal shopping mall which cou 阅读全文
posted @ 2018-03-27 08:12 王清河 阅读(110) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示