![](https://img-blog.csdnimg.cn/20201014180756780.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
链表
shishiness
这个作者很懒,什么都没留下…
展开
-
pat 甲级 链表 A1074 Reversing Linked List (25分)(注意细节 仔细读题
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→4; if K=4, you must output 4→3→2原创 2020-07-21 10:10:01 · 85 阅读 · 0 评论 -
pat 甲级 链表 A1032 Sharing (25分)
1032 Sharing (25分)To store English words, one method is to use linked lists and store a word letter by letter. To save some space, we may let the words share the same sublist if they share the same suffix. For example, loading and being are stored as sho原创 2020-07-21 09:22:57 · 75 阅读 · 0 评论 -
pat 甲级 A1133 Splitting A Linked List (25分)(简单
1133 Splitting A Linked List (25分)Given a singly linked list, you are supposed to rearrange its elements so that all the negative values appear before all of the non-negatives, and all the values in [0, K] appear before all those greater than K. The orde原创 2020-08-28 19:10:28 · 61 阅读 · 0 评论 -
pat 甲级 A1052 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-08-28 19:10:48 · 110 阅读 · 0 评论 -
pat 甲级 链表 A1097 Deduplication on a Linked List (25分)
1097 Deduplication on a Linked List (25分)Given a singly linked list L with integer keys, you are supposed to remove the nodes with duplicated absolute values of the keys. That is, for each value K, only the first node of which the value or absolute value原创 2020-07-21 01:56:48 · 65 阅读 · 0 评论