81. Search in Rotated Sorted Array II

Problem description:

Suppose an array sorted in ascending order is rotated at some pivot unknown to you beforehand.

(i.e., [0,0,1,2,2,5,6] might become [2,5,6,0,0,1,2]).

Readmore

153. Find Minimum in Rotated Sorted Array

Problem description:

Suppose an array sorted in ascending order is rotated at some pivot unknown to you beforehand.

(i.e., [0,1,2,4,5,6,7] might become [4,5,6,7,0,1,2]).

Readmore

48. Rotate Image

Problem description:

You are given an n x n 2D matrix representing an image.

Readmore

369. Plus One Linked List

Problem Description:
Given a non-negative integer represented as non-empty a singly linked list of digits, plus one to the integer.

You may assume the integer do not contain any leading zero, except the number 0 itself.

Readmore

445. Add Two Numbers II

Problem description:
You are given two non-empty linked lists representing two non-negative integers. The most significant digit comes first and each of their nodes contain a single digit. Add the two numbers and return it as a linked list.

Readmore

15. 3Sum

Problem description:

Given an array nums of n integers, are there elements a, b, c in nums such that a + b + c = 0? Find all unique triplets in the array which gives the sum of zero.

Readmore

413. Arithmetic Slices

Problem description:

A sequence of number is called arithmetic if it consists of at least three elements and if the difference between any two consecutive elements is the same.

Readmore

357. Count Numbers with Unique Digits

Problem description:
Given a non-negative integer n, count all numbers with unique digits, x, where 0 ≤ x < 10n.

Example:
Given n = 2, return 91. (The answer should be the total numbers in the range of 0 ≤ x < 100, excluding [11,22,33,44,55,66,77,88,99])

Readmore

95. Unique Binary Search Trees II

Problem description:

Given an integer n, generate all structurally unique BST’s (binary search trees) that store values 1 … n.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
Example:

Input: 3
Output:
[
[1,null,3,2],
[3,2,null,1],
[3,1,null,null,2],
[2,1,3],
[1,null,2,null,3]
]
Explanation:
The above output corresponds to the 5 unique BST's shown below:

1 3 3 2 1
\ / / / \ \
3 2 1 1 3 2
/ / \ \
2 1 2 3

Readmore

96. Unique Binary Search Trees

Problem description:

Given n, how many structurally unique BST’s (binary search trees) that store values 1 … n?

Readmore