LeetCodechevron_rightCategorieschevron_rightbinary tree
park

binary tree

130 problems
Easy: 35Medium: 85Hard: 10

binary tree is one of the most repeated interview dimensions. Start with edge-safe fundamentals, then move into pattern-level trade-offs.

Interview Signal

Frequently tests problem modeling, edge handling, and verbal clarity.

Common Pitfall

Template-only answers break under follow-up questioning.

Practice Strategy

Practice in 3-5 problem rounds and always review complexity alternatives.

Recommended Progression

Problem bank

binary tree problem bank

Start with a compact scan-friendly list and progressively load more so the topic page stays readable even when the corpus is large.

Progressive topic library

Built for large topic sets: scan the structure first, then go deeper.

hourglass_bottomScroll to continue
search
tuneDifficulty

Showing 24 / 130 problems

+24 per load
#TitleDifficulty
94

Binary Tree Inorder Traversal

Binary Tree Inorder Traversal asks you to visit left subtree, node, then right subtree without losing position while mov…

Easy
95

Unique Binary Search Trees II

Generate all structurally unique BSTs with values 1 to n using backtracking and recursive tree construction techniques.

Medium
96

Unique Binary Search Trees

Given n nodes, calculate the number of unique binary search trees (BSTs) that can be formed with values from 1 to n.

Medium
98

Validate Binary Search Tree

Validate Binary Search Tree problem checks if a binary tree satisfies BST properties using tree traversal and state trac…

Medium
99

Recover Binary Search Tree

Recover a BST where two nodes are swapped by mistake using in-order traversal and careful state tracking to restore corr…

Medium
100

Same Tree

Check whether two binary trees are identical by comparing structure and node values using DFS or BFS traversal strategie…

Easy
101

Symmetric Tree

Determine if a binary tree is symmetric by comparing left and right subtrees using DFS or BFS traversal techniques effic…

Easy
102

Binary Tree Level Order Traversal

Perform a level order traversal on a binary tree using BFS to return node values level by level.

Medium
103

Binary Tree Zigzag Level Order Traversal

Traverse a binary tree in zigzag level order, alternating directions at each depth using BFS and state tracking techniqu…

Medium
104

Maximum Depth of Binary Tree

Find the maximum depth of a binary tree using traversal techniques to track the longest path from root to leaf.

Easy
105

Construct Binary Tree from Preorder and Inorder Traversal

Construct a binary tree using preorder and inorder traversal arrays, leveraging array scanning and hash table lookups.

Medium
106

Construct Binary Tree from Inorder and Postorder Traversal

Reconstruct a binary tree from given inorder and postorder arrays using array scanning and hash lookup to optimize recur…

Medium
107

Binary Tree Level Order Traversal II

Return a bottom-up level order traversal of a binary tree, processing nodes left to right while tracking each level accu…

Medium
108

Convert Sorted Array to Binary Search Tree

Pick the middle element as root at each step so the sorted array becomes a height-balanced BST with valid ordering.

Easy
109

Convert Sorted List to Binary Search Tree

Convert a sorted singly linked list into a height-balanced BST using pointer manipulation and divide-and-conquer recursi…

Medium
110

Balanced Binary Tree

Determine if a binary tree is height-balanced using tree traversal and state tracking techniques.

Easy
111

Minimum Depth of Binary Tree

Find the minimum depth of a binary tree, which is the shortest path from the root node to the nearest leaf node.

Easy
112

Path Sum

Determine if a binary tree has a root-to-leaf path where the sum of node values equals a given target sum, using DFS or …

Easy
113

Path Sum II

Find all root-to-leaf paths in a binary tree where the sum of node values equals a given target using DFS backtracking.

Medium
114

Flatten Binary Tree to Linked List

Flatten a binary tree into a right-skewed linked list by manipulating pointers following a pre-order traversal, handling…

Medium
116

Populating Next Right Pointers in Each Node

Connect each node across every level by reusing established next links to traverse a perfect binary tree without extra q…

Medium
117

Populating Next Right Pointers in Each Node II

Populate each next pointer in a binary tree to its immediate right node, handling nulls and uneven levels efficiently us…

Medium
124

Binary Tree Maximum Path Sum

Calculate the maximum sum of any path in a binary tree by exploring all node sequences using DFS and dynamic programming…

Hard
129

Sum Root to Leaf Numbers

Calculate the sum of all root-to-leaf numbers in a binary tree where each path represents a number.

Medium

swap_vertScroll inside the bank to auto-load more

Related Patterns

Binary Tree LeetCode Problems: 130 Solutions