11 2021 档案

链表remove系列 203, 83, 82, 19, 1171, 234, 160, 138,
摘要:203. Remove Linked List Elements Easy Given the head of a linked list and an integer val, remove all the nodes of the linked list that has Node.val == 阅读全文

posted @ 2021-11-29 01:16 xiaoyongyong 阅读(144) 评论(0) 推荐(0)

链表系列
摘要:206. Reverse Linked List Easy 9329166Add to ListShare Given the head of a singly linked list, reverse the list, and return the reversed list. Example 阅读全文

posted @ 2021-11-24 11:46 xiaoyongyong 阅读(49) 评论(0) 推荐(0)

链表linkedlist系列
摘要:206. Reverse Linked List Easy Given the head of a singly linked list, reverse the list, and return the reversed list. Example 1: Input: head = [1,2,3, 阅读全文

posted @ 2021-11-24 11:46 xiaoyongyong 阅读(54) 评论(0) 推荐(0)

num of island 数岛屿 系列
摘要:1254. Number of Closed Islands Medium Given a 2D grid consists of 0s (land) and 1s (water). An island is a maximal 4-directionally connected group of  阅读全文

posted @ 2021-11-22 09:18 xiaoyongyong 阅读(79) 评论(0) 推荐(0)

并查集(UnionFind) 系列 547,lintcode434,128,684,399,721,827,1631,1202
摘要:547. Number of Provinces Medium There are n cities. Some of them are connected, while some are not. If city a is connected directly with city b, and c 阅读全文

posted @ 2021-11-21 03:11 xiaoyongyong 阅读(82) 评论(0) 推荐(0)

Trie 系列 208, 211, 212, 421, 386, 1233, 588, 745
摘要:208. Implement Trie (Prefix Tree) Medium A trie (pronounced as "try") or prefix tree is a tree data structure used to efficiently store and retrieve k 阅读全文

posted @ 2021-11-21 00:35 xiaoyongyong 阅读(148) 评论(0) 推荐(0)

单调队列 monotonic queue 239, 862, 3835
摘要:239. Sliding Window Maximum Hard You are given an array of integers nums, there is a sliding window of size k which is moving from the very left of th 阅读全文

posted @ 2021-11-10 09:50 xiaoyongyong 阅读(89) 评论(0) 推荐(0)

单调栈(monotonic stack)系列 496,503,316,402,84,85,962,42,1776,321, 3816
摘要:496. Next Greater Element I The next greater element of some element x in an array is the first greater element that is to the right of x in the same 阅读全文

posted @ 2021-11-05 11:59 xiaoyongyong 阅读(99) 评论(0) 推荐(0)