
PAT刷题
沧海漂游_
这个作者很懒,什么都没留下…
展开
-
[PAT] 1028. List Sorting (25)
题目Excel can sort records according to any column. Now you are supposed to imitate this function.InputEach input file contains one test case. For each case, the first line contains two integers N...原创 2018-02-12 23:22:14 · 211 阅读 · 0 评论 -
[PAT] C++ 1142. Maximal Clique (25)
题目A clique is a subset of vertices of an undirected graph such that every two distinct vertices in the clique are adjacent. A maximal clique is a clique that cannot be extended by including one more...原创 2018-03-18 22:10:59 · 862 阅读 · 0 评论 -
[PAT] C++ 1140. Look-and-say Sequence (20)
题目Look-and-say sequence is a sequence of integers as the following:D, D1, D111, D113, D11231, D112213111, … where D is in [0, 9] except 1. The (n+1)st number is a kind of description of the nth n...原创 2018-03-18 22:06:04 · 303 阅读 · 0 评论 -
[PAT] c++ 1143. Lowest Common Ancestor (30)
题目The lowest common ancestor (LCA) of two nodes U and V in a tree is the deepest node that has both U and V as descendants.A binary search tree (BST) is recursively defined as a binary tree which ...原创 2018-03-18 22:03:07 · 2002 阅读 · 0 评论 -
[PAT][ C++] 1026. Table Tennis (30)
题目A table tennis club has N tables available to the public. The tables are numbered from 1 to N. For any pair of players, if there are some tables open when they arrive, they will be assigned to the...原创 2018-03-04 14:30:04 · 537 阅读 · 0 评论 -
[PAT] 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 admi...原创 2018-02-15 00:46:54 · 248 阅读 · 0 评论 -
[PAT] 1029. Median (25)
题目Given an increasing sequence S of N integers, the median is the number at the middle position. For example, the median of S1={11, 12, 13, 14} is 12, and the median of S2={9, 10, 15, 16, 17} is 15....原创 2018-02-26 15:50:42 · 279 阅读 · 0 评论 -
[PAT] 1065. A+B and C (64bit) (20)
题目Given three integers A, B and C in [−263−263{-2}^{63},263263{2}^{63}], you are supposed to tell whether A+B > C.Input Specification:The first line of the input gives the positive number of ...原创 2018-02-12 17:02:22 · 191 阅读 · 0 评论 -
[PAT] 1025. PAT Ranking (25)
题目Programming Ability Test (PAT) is organized by the College of Computer Science and Technology of Zhejiang University. Each test is supposed to run simultaneously in several places, and the ranklis...原创 2018-02-12 22:02:33 · 232 阅读 · 0 评论 -
[PAT] C++ 1141. PAT Ranking of Institutions (25)
题目After each PAT, the PAT Center will announce the ranking of institutions based on their students’ performances. Now you are asked to generate the ranklist.Input Specification:Each input file c...原创 2018-03-18 22:13:48 · 584 阅读 · 0 评论