- 博客(98)
- 资源 (1)
- 收藏
- 关注
原创 1095. Cars on Campus (30)
题目:Zhejiang University has 6 campuses and a lot of gates. From each gate we can collect the in/out times and the plate numbers of the cars crossing the gate. Now with all the information availab
2015-03-16 11:27:03 2281 1
原创 1094. The Largest Generation (25)
题目:A family hierarchy is usually presented by a pedigree tree where all the nodes on the same level belong to the same generation. Your task is to find the generation with the largest population
2015-03-16 11:26:20 976
原创 1093. Count PAT's (25)
题目:The string APPAPT contains two PAT's as substrings. The first one is formed by the 2nd, the 4th, and the 6th characters, and the second one is formed by the 3rd, the 4th, and the 6th characte
2015-03-16 11:24:09 1367
原创 1092. To Buy or Not to Buy (20)
题目:Eva would like to make a string of beads with her favorite colors so she went to a small shop to buy some beads. There were many colorful strings of beads. However the owner of the shop would
2015-03-16 11:22:38 522
原创 1091. Acute Stroke (30)
题目:One important factor to identify acute stroke (急性脑卒中) is the volume of the stroke core. Given the results of image analysis in which the core regions are identified in each MRI slice, your jo
2015-03-02 19:30:43 658
原创 1090. Highest Price in Supply Chain (25)
题目:A supply chain is a network of retailers(零售商), distributors(经销商), and suppliers(供应商)-- everyone involved in moving a product from supplier to customer.Starting from one root supplier, eve
2015-03-02 19:29:22 624
原创 1089. Insert or Merge (25)
题目:According to Wikipedia:Insertion sort iterates, consuming one input element each repetition, and growing a sorted output list. Each iteration, insertion sort removes one element from the
2015-03-02 19:28:49 1090 1
原创 1088. Rational Arithmetic (20)
题目:For two rational numbers, your task is to implement the basic arithmetics, that is, to calculate their sum, difference, product and quotient.Input Specification:Each input file contai
2015-03-02 19:27:33 606
原创 1087. All Roads Lead to Rome (30)
题目:Indeed there are many different tourist routes from our city to Rome. You are supposed to find your clients the route with the least cost while gaining the most happiness.Input Specificat
2015-03-02 19:26:03 852
原创 1086. Tree Traversals Again (25)
题目:An inorder binary tree traversal can be implemented in a non-recursive way with a stack. For example, suppose that when a 6-node binary tree (with the keys numbered from 1 to 6) is traver
2015-03-02 19:22:54 494
原创 1085. Perfect Sequence (25)
题目:Given a sequence of positive integers and another positive integer p. The sequence is said to be a "perfect sequence" if M Now given a sequence and a parameter p, you are supposed to find
2015-03-02 19:22:23 980
原创 1084. Broken Keyboard (20)
题目:On a broken keyboard, some of the keys are worn out. So when you type some sentences, the characters corresponding to those keys will not appear on screen.Now given a string that you are
2015-03-02 19:21:06 573
原创 1083. List Grades (25)
题目:Given a list of N student records with name, ID and grade. You are supposed to sort the records with respect to the grade in non-increasing order, and output those student records of which th
2015-03-02 19:19:37 516
原创 1082. Read Number in Chinese (25)
题目:Given an integer with no more than 9 digits, you are supposed to read it in the traditional Chinese way. Output "Fu" first if it is negative. For example, -123456789 is read as "Fu yi Yi er Q
2015-03-02 19:17:54 434
原创 1081. Rational Sum (20)
题目:Given N rational numbers in the form "numerator/denominator", you are supposed to calculate their sum.Input Specification:Each input file contains one test case. Each case starts with
2015-03-02 19:16:28 464
原创 1080. Graduate Admission (30)
题目:It is said that in 2013, there were about 100 graduate schools ready to proceed over 40,000 applications in Zhejiang Province. It would help a lot if you could write a program to automate the
2015-03-02 19:15:16 500
原创 1079. Total Sales of Supply Chain (25)
题目:A supply chain is a network of retailers(零售商), distributors(经销商), and suppliers(供应商)-- everyone involved in moving a product from supplier to customer.Starting from one root supplier, eve
2015-03-02 19:14:34 652
原创 1078. Hashing (25)
题目: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. The hash function is defined to be "H(key
2015-03-02 19:13:15 354
原创 1077. Kuchiguse (20)
题目:The Japanese language is notorious for its sentence ending particles. Personal preference of such particles can be considered as a reflection of the speaker's personality. Such a preference i
2015-03-02 19:06:23 588
原创 1076. Forwards on Weibo (30)
题目:Weibo is known as the Chinese version of Twitter. One user on Weibo may have many followers, and may follow many other users as well. Hence a social network is formed with followers relations
2015-03-02 18:59:29 437
原创 1075. PAT Judge (25)
题目:The ranklist of PAT is generated from the status list, which shows the scores of the submittions. This time you are supposed to generate the ranklist for PAT.Input Specification:Each
2015-03-02 18:57:53 1001
原创 1074. Reversing Linked List (25)
题目:Given a constant K and a singly linked list L, you are supposed to reverse the links of every K elements on L. For example, given L being 1→2→3→4→5→6, if K = 3, then you must output 3→2→1→6→5
2015-03-02 18:56:22 579
原创 1073. Scientific Notation (20)
题目:Scientific notation is the way that scientists easily handle very large numbers or very small numbers. The notation matches the regular expression [+-][1-9]"."[0-9]+E[+-][0-9]+ which means th
2015-03-02 18:55:45 790
原创 1072. Gas Station (30)
题目:A gas station has to be built at such a location that the minimum distance between the station and any of the residential housing is as far away as possible. However it must guarantee that al
2015-03-02 18:54:13 479
原创 1071. Speech Patterns (25)
题目:People often have a preference among synonyms of the same word. For example, some may prefer "the police", while others may prefer "the cops". Analyzing such patterns can help to narrow down
2015-03-02 18:52:45 445
原创 1070. Mooncake (25)
题目:Mooncake is a Chinese bakery product traditionally eaten during the Mid-Autumn Festival. Many types of fillings and crusts can be found in traditional mooncakes according to the region's cult
2015-03-02 18:50:55 463
原创 1069. The Black Hole of Numbers (20)
题目:For any 4-digit integer except the ones with all the digits being the same, if we sort the digits in non-increasing order first, and then in non-decreasing order, a new number can be obtained
2015-03-02 18:49:54 408
原创 1068. Find More Coins (30)
题目: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 could accept all kinds of coins as payments.
2015-03-02 18:48:59 545
原创 1067. Sort with Swap(0,*) (25)
题目: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 that is allowed to use? For example, to sort
2015-02-03 20:32:15 497
原创 1066. Root of AVL Tree (25)
题目:An AVL tree is a self-balancing binary search tree. In an AVL tree, the heights of the two child subtrees of any node differ by at most one; if at any time they differ by more than one, rebal
2015-02-03 00:43:26 523
原创 1065. A+B and C (64bit) (20)
题目:Given three integers A, B and C in [-263, 263], you are supposed to tell whether A+B > C.Input Specification:The first line of the input gives the positive number of test cases, T (
2015-02-02 23:21:16 471
原创 1064. Complete Binary Search Tree (30)
题目:A Binary Search Tree (BST) is recursively defined as a binary tree which has the following properties:The left subtree of a node contains only nodes with keys less than the node's key.
2015-02-02 23:17:44 429
原创 1063. Set Similarity (25)
题目: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 two sets, and Nt is the total number of d
2015-02-02 23:06:04 551
原创 1062. Talent and Virtue (25)
题目:About 900 years ago, a Chinese philosopher Sima Guang wrote a history book in which he talked about people's talent and virtue. According to his theory, a man being outstanding in both talent
2015-02-02 22:48:07 445
原创 1061. Dating (20)
题目:Sherlock Holmes received a note with some strange strings: "Let's date! 3485djDkxh4hhGE 2984akDfkkkkggEdsb s&hgsfdk d&Hyscvnm". It took him only a minute to figure out that those strange stri
2015-02-02 22:43:43 373
原创 1060. Are They Equal (25)
题目: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 simple chopping. Now given the number of
2015-02-02 22:38:03 416
原创 1059. Prime Factors (25)
题目:Given any positive integer N, you are supposed to find all of its prime factors, and write them in the format N = p1^k1* p2^k2 *…*pm^km.Input Specification:Each input file contains on
2015-02-02 22:31:11 370
原创 1058. A+B in Hogwarts (20)
题目:If you are a fan of Harry Potter, you would know the world of magic has its own currency system -- as Hagrid explained it to Harry, "Seventeen silver Sickles to a Galleon and twenty-nine Knut
2015-02-02 22:24:52 354
原创 1057. Stack (30)
题目:Stack is one of the most fundamental data structures, which is based on the principle of Last In First Out (LIFO). The basic operations include Push (inserting an element onto the top positio
2015-02-02 22:17:19 399
原创 1056. Mice and Rice (25)
题目:Mice and Rice is the name of a programming contest in which each programmer must write a piece of code to control the movements of a mouse in a given map. The goal of each mouse is to eat as
2015-02-02 21:46:58 1840
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人