Skip to content

Here I will record all the useful information that I learned or gained from praticing LeetCode problems

Notifications You must be signed in to change notification settings

BrandonBian/leetcode

Repository files navigation

Table of Contents

  • Section 0: Patterns
  • Section 1: Algorithms
  • Section 2: Data Structures
  • Section 3: Time & Space Complexities
  • Section 4: Auxiliary Collection of Problems & Solutions

Section 0: Patterns

Condition Algorithms to / can Use Data Structures to / can Use
Input array is sorted Binary Search + Two Pointers --
Asking for all permutations / subsets / combinations DFS Backtracking --
Finding the minimum / maximum / k-th position Binary Search + Heap --
Binary tree / binary search tree BFS using queues + DFS using recursion BT + BST
Path finding on a grid / matrix BFS using queues + DFS using recursion + Step towards directions --
Linked list Two Pointers + Dummy Node Linked List
K-Sum / partitioning Two Pointers --
Substring / subarray on linear structure Sliding Window (Two Pointers) --
Dealing with brackets -- Stack
Finding occurrence of a certain pattern -- Hash Table (Dict, Counter)
Maximum / minimum subarray / subset / options Dynamic Programming --

Section 1: Algorithms

ID Algorithm When To Use Study Guide Problems Solutions Important Key Points
1 Binary Search "minimizing / maximizing / find K-th position" Guide Problems Solutions A Template
2 Greatest Common Divisor (GCD) & Least Common Multiple (LCM) "total number of positive integers <= N which are divisible by a or b or c" Guide - - Calculation Formulae in Python
3 DFS Recursion & Backtracking "combination / combination sum / permutations / subsets" Guide Problems Solutions A Template
4 Two Pointers "K-Sum / partitioning / sorting" Guide Problems Solutions -
5 Topological DFS & BFS "path finding in a grid or matrix" - Problems Solutions
6 Sorting Methods - Guide Problems Solutions
7 Dynamic Programming - Merged with Problems Problems Solutions
8 Prefix & Sufix Sum

Section 2: Data Structures

ID Data Structure Common Topics / Applications Study Guide Problems Solutions Important Key Points
1 Binary Tree & Binary Search Trees "BT and BST traversal / deleting & inserting node / root-to-leaf DFS / construction / validation" Guide Problems Solutions Traversal Templates
2 Hash Table "using Counter / Set / Dictionary / Pattern Hashing" Guide Problems Solutions Using and Sorting Python Dictionary & Counter
3 Linked List "Linked List cycle detection / cycle locating / slow-fast pointers / dummy nodes / double pointers" Guide Problems Solutions -
4 Binary Indexed Tree / Fenwick Tree
5 Heaps
6 Trie / Prefix Tree

Section 3: Time & Space Complexities


Section 4: Auxiliary Problems & Solutions

4.1 LeetCode Top 100 - [Problems] | [Solutions]

4.2 LintCode Top 100 - [Problems] | [Solutions]

4.3 LintCode Chapter-by-Chapter Practice - [Problems] | [Solutions]

About

Here I will record all the useful information that I learned or gained from praticing LeetCode problems

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published