PAT甲级
整理一些PAT甲级的题目,可能不会很全,有些题目以前就做过了,不一定一一整理。
_WuZHua
初入软件,自学算法,多多指教!
展开
-
PAT(甲级)2019年冬季考试——题解+总结
PAT(甲级)2019年冬季考试总结写在前头:考了字符串、链表(伪链表)、图、树。考点比较均衡。本次考试难度还行,需要较扎实的数据结构底子,对于字符串处理的技巧有一定的要求。说句题外话,字符串是个重点,主要因为很多人会忽视字符串。2018-2019年的GPLT(团体程序设计天梯赛)的l1最后一题就是一道字符串处理,当时卡住了不知道多少人,但其实稍微做做字符串的题目之后就会发现,那题不过如此。这次PAT甲级的第一题也是不过如此,但很可惜,我当时也忽视了字符串的处理,错失甲满。。。Good in原创 2020-07-21 22:58:14 · 1089 阅读 · 0 评论 -
1014 Waiting in Line (30分)
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 for the customers to wait in line are:The space inside the yellow line in fr原创 2020-07-16 15:56:05 · 162 阅读 · 0 评论 -
1004 Counting Leaves (30分)
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 with a line containing 0<N&原创 2020-07-16 15:07:40 · 122 阅读 · 0 评论 -
1052 Linked List Sorting (25分)
1052 Linked List Sorting (25分)A linked list consists of a series of structures, which are not necessarily adjacent in memory. We assume that each structure contains an integer key and a Next pointer to the next structure. Now given a linked list, you are原创 2020-06-30 23:17:13 · 230 阅读 · 0 评论 -
1048 Find Coins (25分)
1048 Find Coins (25分)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. However, there was a special requirement o原创 2020-06-21 11:11:11 · 260 阅读 · 0 评论 -
L3-003 社交集群 (30分)
我的思路其实很简单 这题是比较标准的 并查集 类型的题目。 主要思想就是一个常规的并查集数组 f[MAXN] 保存各个成员之间的朋友关系 那么不同兴趣圈的人怎么建立朋友关系呢? 我的办法是通过另一个变量存储不同的兴趣圈里的人是哪些,然后在读取数据的时候,一个人若是发现有兴趣A,则遍历一遍兴趣A所在的兴趣圈, 与...原创 2020-02-08 15:39:53 · 814 阅读 · 0 评论