111. Minimum Depth of Binary Tree

Problem description:

Given a binary tree, find its minimum depth.

Readmore

437. Path Sum III

Problem description:

You are given a binary tree in which each node contains an integer value.

Readmore

113. Path Sum II

Problem description:

Given a binary tree and a sum, find all root-to-leaf paths where each path’s sum equals the given sum.

Readmore

112. Path Sum

Problem description:

Given a binary tree and a sum, determine if the tree has a root-to-leaf path such that adding up all the values along the path equals the given sum.

Readmore

222. Count Complete Tree Nodes

Problem description:

Given a complete binary tree, count the number of nodes.

Readmore

note-Tree

Tree

  • Complete binary tree:
    Definition of a complete binary tree from Wikipedia:
    In a complete binary tree every level, except possibly the last, is completely filled, and all nodes in the last level are as far left as possible. It can have between 1 and 2^h nodes inclusive at the last level h.

Readmore

376. Wiggle Subsequence

Readmore

698. Partition to K Equal Sum Subsets

Problem description:

Given an array of integers nums and a positive integer k, find whether it’s possible to divide this array into k non-empty subsets whose sums are all equal.

Readmore

416. Partition Equal Subset Sum

Problem description:

Given a non-empty array containing only positive integers, find if the array can be partitioned into two subsets such that the sum of elements in both subsets is equal.

Readmore

300. Longest Increasing Subsequence

Problem description:

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

Readmore