![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
PAT(Advanced Level
Adolphrocs
这个作者很懒,什么都没留下…
展开
-
PAT(Advanced Level) 1015 Reversible Primes (20分)
PAT(Advanced Level) 1015 Reversible Primes (20分) 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 rev...原创 2020-02-26 14:01:58 · 286 阅读 · 0 评论 -
PAT (Advanced Level) 1014 Waiting in Line (30分)
PAT (Advanced Level) 1014 Waiting in Line (30分) Suppose a bank has N windows open for service. There is a yellow line in front of the windows which devides the waiting area into two parts. The rules f...原创 2020-02-25 18:45:39 · 262 阅读 · 0 评论 -
PAT (Advanced Level) 1013 Battle Over Cities (25分)
PAT (Advanced Level) 1013 Battle Over Cities (25分) 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 ...原创 2020-02-22 14:43:45 · 190 阅读 · 0 评论 -
PAT (Advanced Level) 1012 The Best Rank (25分)
PAT (Advanced Level) 1012 The Best Rank (25分) To evaluate the performance of our first year CS majored students, we consider their grades of three courses only: C - C Programming Language, M - Mathema...原创 2020-02-22 14:16:30 · 189 阅读 · 0 评论 -
PAT(Advanced Level) 1011 World Cup Betting (20分)
PAT(Advanced Level) 1011 World Cup Betting (20分) 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 bat...原创 2020-02-20 18:19:38 · 205 阅读 · 0 评论 -
PAT (Advanced Level) 1010 Radix (25分)
PAT (Advanced Level) 1010 Radix (25分) 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 binary numb...原创 2020-02-20 12:05:46 · 196 阅读 · 0 评论 -
PAT(Advanced Level) 1009 Product of Polynomials (25分)
PAT(Advanced Level) 1009 Product of Polynomials (25分) This time, you are supposed to find A×B where A and B are two polynomials. Input Specification: Each input file contains one test case. Each case ...原创 2020-02-18 16:57:31 · 183 阅读 · 0 评论 -
PAT(Advanced Level) 1008 Elevator (20分)
PAT(Advanced Level) 1008 Elevator (20分) 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 elevator will ...原创 2020-02-18 15:58:55 · 159 阅读 · 0 评论 -
PAT(Advanced Level) 1007 Maximum Subsequence Sum (25分)
PAT(Advanced Level) 1007 Maximum Subsequence Sum (25分) Given a sequence of K integers { N1N_1N1, N2N_2N2, …, NKN_KNK}. A continuous subsequence is defined to be { NiN_iNi , Ni+1N_{i+1}Ni+1...原创 2020-02-17 21:15:16 · 157 阅读 · 0 评论 -
PAT(Advanced Level) 1006 Sign In and Sign Out (25分)
PAT(Advanced Level) 1006 Sign In and Sign Out (25分) 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 do...原创 2020-02-15 20:42:20 · 173 阅读 · 0 评论 -
PAT (Advanced Level) 1005 Spell It Right (20分)
PAT (Advanced Level) 1005 Spell It Right (20分) 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 Specification...原创 2020-02-15 17:32:33 · 163 阅读 · 0 评论 -
PAT (Advanced Level) 1004 Counting Leaves (30分)
PAT (Advanced Level) 1004 Counting Leaves (30分) 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 input...原创 2020-02-15 17:18:11 · 161 阅读 · 0 评论 -
PAT (Advanced Level) Practice 1003 Emergency (25分)
PAT (Advanced Level) Practice 1003 Emergency (25分) #include <bits/stdc++.h> using namespace std; int n, m; vector<pair<int, int>> graph[505]; int d[505], vis[505], roadnum[505]; lon...原创 2020-02-15 16:10:44 · 204 阅读 · 0 评论 -
PAT (Advanced Level) Practice 1002 A+B for Polynomials (25分)
This time, you are supposed to find A+B where A and B are two polynomials. Input Specification: Each input file contains one test case. Each case occupies 2 lines, and each line contains the informati...原创 2020-02-12 21:53:36 · 174 阅读 · 0 评论 -
PAT (Advanced Level) Practice 1001 A+B Format
Calculate a+b and output the sum in standard format -- that is, the digits must be separated into groups of three by commas (unless there are less than four digits). Input Specification: Each input f...原创 2020-02-12 21:22:11 · 163 阅读 · 0 评论