← Resources

Personal reference

Practice

Problems with worked solutions — brute force first, then the optimal approach, with best and worst case complexity for each.

22 problems · DSA notes → · Dictionary →

Arrays & Hashing

Two Sum
Easy
Contains Duplicate
Easy
Valid Anagram
Easy
Group Anagrams
Medium
Top K Frequent Elements
Medium
Product of Array Except Self
Medium

Two Pointers & Sliding Window

Container With Most Water
Medium
3Sum
Medium
Best Time to Buy and Sell Stock
Easy
Longest Substring Without Repeating Characters
Medium

Stack

Valid Parentheses
Easy

Linked List

Reverse Linked List
Easy
Linked List Cycle
Easy
Merge Two Sorted Lists
Easy

Intervals

Merge Intervals
Medium

Trees

Binary Tree Level Order Traversal
Medium
Validate Binary Search Tree
Medium

Heap

Kth Largest Element in an Array
Medium

Graphs

Number of Islands
Medium

Dynamic Programming

Climbing Stairs
Easy
Maximum Subarray
Medium
House Robber
Medium