75. Sort Colors 题目 Given an array with n objects colored red, white or blue, sort them so that objects of the …
分类:LeetCode题目解答
74. Search a 2D Matrix
74. Search a 2D Matrix 题目 Write an efficient algorithm that searches for a value in an m x n matrix. This matr…
76. Minimum Window Substring
76. Minimum Window Substring 题目 Given a string S and a string T, find the minimum window in S which will conta…
77. Combinations
77. Combinations 题目 Given two integers n and k, return all possible combinations of k numbers out of 1 ... n. …
79. Word Search
79. Word Search 题目 Given a 2D board and a word, find if the word exists in the grid. The word can be construct…
78. Subsets
78. Subsets 题目 Given a set of distinct integers, nums, return all possible subsets (the power set). Note: The …
80. Remove Duplicates from Sorted Array II
80. Remove Duplicates from Sorted Array II 题目 Follow up for "Remove Duplicates": What if duplicates are allowe…
82. Remove Duplicates from Sorted List II && i
题目 83. Remove Duplicates from Sorted List Given a sorted linked list, delete all duplicates such that each ele…
81. Search in Rotated Sorted Array II
81. Search in Rotated Sorted Array II 题目 Follow up for "Search in Rotated Sorted Array": What if duplicates ar…
84. Largest Rectangle in Histogram-hard
84. Largest Rectangle in Histogram 题目 Given n non-negative integers representing the histogram's bar height wh…
86. Partition List
86. Partition List 题目 Given a linked list and a value x, partition it such that all nodes less than x come bef…
85. Maximal Rectangle
85. Maximal Rectangle 题目 Given a 2D binary matrix filled with 0's and 1's, find the largest rectangle containi…