文章 224
评论 11
浏览 167379
410. 分割数组的最大值

410. 分割数组的最大值

给定一个非负整数数组nums和一个整数m ,你需要将这个数组分成m个非空的连续子数组。 设计一个算法使得这m个子数组各自和的最大值最小。

301. 删除无效的括号

301. 删除无效的括号

给你一个由若干括号和字母组成的字符串 s ,删除最小数量的无效括号,使得输入的字符串有效。 返回所有可能的结果。答案可以按任意顺序返回。

79. 单词搜索

79. 单词搜索

Given an m x n grid of characters board and a string word, return true if word exists in the grid.

138. Copy List with Random Pointer

138. Copy List with Random Pointer

A linked list of length n is given such that each node contains an additional random pointer, which could point to any node in the list, or null.Construct a deep copy of the list.

1143. Longest Common Subsequence

1143. Longest Common Subsequence

Given two strings text1 and text2, return common subsequence. If there is no common subsequence, return 0.

1335. Minimum Difficulty of a Job Schedule

1335. Minimum Difficulty of a Job Schedule

You want to schedule a list of jobs in d days. Jobs are dependent (i.e To work on the i-th job, you have to finish all the jobs j where 0 <= j < i).

73. Set Matrix Zeroes

73. Set Matrix Zeroes

Given an m x n matrix. If an element is 0, set its entire row and column to 0. Do it in-place.

重排奇偶有序链表

重排奇偶有序链表

给定一个链表,其中奇数位是升序的,偶数位是降序的,实现链表的排序。

1496. Path Crossing

1496. Path Crossing

Return True if the path crosses itself at any point, that is, if at any time you are on a location you've previously visited. Return False otherwise.

680. Valid Palindrome II

680. Valid Palindrome II

Given a non-empty string s, you may delete at most one character. Judge whether you can make it a palindrome.

String - 71. Simplify Path

String - 71. Simplify Path

Given an absolute path for a file (Unix-style), simplify it. Or in other words, convert it to the canonical path.

String - 67. Add Binary

String - 67. Add Binary

Given two binary strings, return their sum (also a binary string).

Math - 50. Pow(x, n)

Math - 50. Pow(x, n)

Implement pow(x, n), which calculates x raised to the power n (xn).

String - 44. Wildcard Matching

String - 44. Wildcard Matching

Given an input string (s) and a pattern (p), implement wildcard pattern matching with support for '?' and '*'.

DFS&BFS - 37. Sudoku Solver

DFS&BFS - 37. Sudoku Solver

Write a program to solve a Sudoku puzzle by filling the empty cells.

Array - 36. Valid Sudoku

Array - 36. Valid Sudoku

Determine if a 9x9 Sudoku board is valid.

Array - 57. Insert Interval

Array - 57. Insert Interval

Given a set of non-overlapping intervals, insert a new interval into the intervals (merge if necessary).

Binary Search - 378. Kth Smallest Element in a Sorted Matrix

Binary Search - 378. Kth Smallest Element in a Sorted Matrix

Given a n x n matrix where each of the rows and columns are sorted in ascending order, find the kth smallest element in the matrix.

Array - 59. Spiral Matrix II

Array - 59. Spiral Matrix II

Given a positive integer n, generate a square matrix filled with elements from 1 to n2 in spiral order.

Array - 54. Spiral Matrix

Array - 54. Spiral Matrix

Given a matrix of m x n elements (m rows, n columns), return all elements of the matrix in spiral order.

Nothing just happens, it's all part of a plan.