作者归档:在线疯狂

RSS feed of 在线疯狂

[LeetCode]Additive Number

题目描述:

Additive number is a positive integer whose digits can form additive sequence.

A valid additive sequence should contain at least three numbers. Except for the first two numbers, each subsequent number in the sequence must be the sum of ...

继续阅读

[LeetCode]Remove Invalid Parentheses

题目描述:

Remove the minimum number of invalid parentheses in order to make the input string valid. Return all possible results.

Note: The input string may contain letters other than the parentheses ( and ).

Examples:

"()())()" -> ["()()()", "(())()" ...

继续阅读

[LeetCode]Longest Increasing Subsequence

题目描述:

Given an unsorted array of integers, find the length of longest increasing subsequence.

For example,

Given [10, 9, 2, 5, 3, 7, 101, 18],

The longest increasing subsequence is [2, 3, 7, 101], therefore the length is 4. Note ...

继续阅读