PAT
sharon_JIAN
鱼跃此时海,花开彼岸天
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
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 file contains one test case. Each case starts w...原创 2019-06-05 23:01:42 · 275 阅读 · 0 评论 -
1036 Boys vs Girls (25 分)(PAT甲级)(C语言)
This time you are asked to tell the difference between the lowest grade of all the male students and the highest grade of all the female students. Input Specification: Each input file contains one tes...原创 2019-08-30 21:58:38 · 256 阅读 · 0 评论 -
1035 Password (20 分)(C语言)(PAT)
To prepare for PAT, the judge sometimes has to generate random passwords for the users. The problem is that there are always some confusing passwords since it is hard to distinguish 1 (one) from l (L ...原创 2019-08-29 22:04:26 · 237 阅读 · 0 评论 -
1031 Hello World for U (20 分)(PAT)(C语言)
Given any string of N (≥5) characters, you are asked to form the characters into the shape of U. For example, helloworld can be printed as: h d e l l r lowo That is, the characters must be printed...原创 2019-07-28 22:04:13 · 148 阅读 · 0 评论 -
1026 Table Tennis (30 分)(C语言实现)(PAT)
题目解析 维护两个队列,分别为普通用户的编号序列,i以及VIP用户的编号序列。 #include <stdio.h> #include <stdlib.h> #define MaxCustomerNum 10000 #define MaxWindowNum 101 #define EmptyTable -1 #define VIP 1 #define NONVIP 0 s...原创 2019-07-01 02:02:14 · 322 阅读 · 0 评论 -
1025 PAT Ranking (25 分)(C语言实现)(PAT)(排序算法)
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 ranklists w...原创 2019-06-29 22:29:04 · 243 阅读 · 0 评论 -
1024 Palindromic Number (25 分)(C语言实现)(PAT)
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. All single digit numbers are palindromic numbers...原创 2019-06-28 22:40:09 · 220 阅读 · 0 评论 -
1020 Tree Traversals (25 分)(C语言实现)(PAT)
Suppose that all the keys in a binary tree are distinct positive integers. Given the postorder and inorder traversal sequences, you are supposed to output the level order traversal sequence of the cor...原创 2019-06-24 21:23:10 · 373 阅读 · 0 评论 -
1021 Deepest Root (25 分)(C语言实现)(PAT)
A graph which is connected and acyclic can be considered a tree. The height of the tree depends on the selected root. Now you are supposed to find the root that results in a highest tree. Such a root ...原创 2019-06-26 22:58:07 · 344 阅读 · 0 评论 -
1019 General Palindromic Number (20 分)(C语言实现)(PAT)
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. All single digit numbers are palindromic numbers...原创 2019-06-22 21:56:17 · 222 阅读 · 0 评论 -
1013 Battle Over Cities (25 分)(C语言实现)
题目来源自PAT:https://pintia.cn/problem-sets/994805342720868352/problems/994805500414115840 It is vitally important to have all the cities connected by highways in a war. If a city is occupied by the enemy...原创 2019-06-13 22:33:34 · 326 阅读 · 0 评论 -
1006 Sign In and Sign Out (25 分)
题目来源PAT 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. Given the records of signing in’s and ou...原创 2019-06-06 22:57:47 · 145 阅读 · 0 评论 -
1037 Magic Coupon (25 分)(PAT甲级)
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 product, you may get N times the value of that product b...原创 2019-09-02 22:04:44 · 142 阅读 · 0 评论
分享