Skip to content

A collection of LeetCode questions to ace the coding interview! - Created using [LeetHub v2](https://github.com/arunbhardwaj/LeetHub-2.0)

Notifications You must be signed in to change notification settings

mohansaivenkat/LeetCode

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

792 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LeetCode

A collection of LeetCode questions to ace the coding interview! - Created using LeetHub v2

LeetCode Topics

Tree

0094-binary-tree-inorder-traversal
0098-validate-binary-search-tree
0100-same-tree
0101-symmetric-tree
0103-binary-tree-zigzag-level-order-traversal
0104-maximum-depth-of-binary-tree
0108-convert-sorted-array-to-binary-search-tree
0110-balanced-binary-tree
0111-minimum-depth-of-binary-tree
0144-binary-tree-preorder-traversal
0226-invert-binary-tree
0235-lowest-common-ancestor-of-a-binary-search-tree
0236-lowest-common-ancestor-of-a-binary-tree
0257-binary-tree-paths
0783-search-in-a-binary-search-tree
0784-insert-into-a-binary-search-tree

Binary Search Tree

0033-search-in-rotated-sorted-array
0034-find-first-and-last-position-of-element-in-sorted-array
0035-search-insert-position
0069-sqrtx
0098-validate-binary-search-tree
0108-convert-sorted-array-to-binary-search-tree
0162-find-peak-element
0235-lowest-common-ancestor-of-a-binary-search-tree
0349-intersection-of-two-arrays
0350-intersection-of-two-arrays-ii
0540-single-element-in-a-sorted-array
0783-search-in-a-binary-search-tree
0784-insert-into-a-binary-search-tree
0792-binary-search
0882-peak-index-in-a-mountain-array

Binary Tree

0094-binary-tree-inorder-traversal
0098-validate-binary-search-tree
0100-same-tree
0101-symmetric-tree
0103-binary-tree-zigzag-level-order-traversal
0104-maximum-depth-of-binary-tree
0108-convert-sorted-array-to-binary-search-tree
0110-balanced-binary-tree
0111-minimum-depth-of-binary-tree
0144-binary-tree-preorder-traversal
0226-invert-binary-tree
0235-lowest-common-ancestor-of-a-binary-search-tree
0236-lowest-common-ancestor-of-a-binary-tree
0257-binary-tree-paths
0783-search-in-a-binary-search-tree
0784-insert-into-a-binary-search-tree

Array

0001-two-sum
0011-container-with-most-water
0026-remove-duplicates-from-sorted-array
0027-remove-element
0033-search-in-rotated-sorted-array
0034-find-first-and-last-position-of-element-in-sorted-array
0035-search-insert-position
0037-sudoku-solver
0042-trapping-rain-water
0053-maximum-subarray
0066-plus-one
0075-sort-colors
0078-subsets
0084-largest-rectangle-in-histogram
0108-convert-sorted-array-to-binary-search-tree
0121-best-time-to-buy-and-sell-stock
0136-single-number
0162-find-peak-element
0169-majority-element
0189-rotate-array
0198-house-robber
0215-kth-largest-element-in-an-array
0217-contains-duplicate
0219-contains-duplicate-ii
0229-majority-element-ii
0238-product-of-array-except-self
0349-intersection-of-two-arrays
0350-intersection-of-two-arrays-ii
0414-third-maximum-number
0448-find-all-numbers-disappeared-in-an-array
0455-assign-cookies
0485-max-consecutive-ones
0496-next-greater-element-i
0540-single-element-in-a-sorted-array
0566-reshape-the-matrix
0605-can-place-flowers
0628-maximum-product-of-three-numbers
0645-set-mismatch
0682-baseball-game
0724-find-pivot-index
0792-binary-search
0882-peak-index-in-a-mountain-array
1019-squares-of-a-sorted-array
1603-running-sum-of-1d-array
1781-check-if-two-string-arrays-are-equivalent
2277-count-equal-and-divisible-pairs-in-an-array
2888-minimum-index-of-a-valid-split
3226-minimum-number-game

String

0003-longest-substring-without-repeating-characters
0013-roman-to-integer
0022-generate-parentheses
0028-find-the-index-of-the-first-occurrence-in-a-string
0058-length-of-last-word
0067-add-binary
0091-decode-ways
0125-valid-palindrome
0131-palindrome-partitioning
0242-valid-anagram
0257-binary-tree-paths
0345-reverse-vowels-of-a-string
0383-ransom-note
0387-first-unique-character-in-a-string
0389-find-the-difference
0392-is-subsequence
0409-longest-palindrome
0412-fizz-buzz
0782-jewels-and-stones
1781-check-if-two-string-arrays-are-equivalent
1818-maximum-score-from-removing-substrings

Depth-First Search

0094-binary-tree-inorder-traversal
0098-validate-binary-search-tree
0100-same-tree
0101-symmetric-tree
0104-maximum-depth-of-binary-tree
0110-balanced-binary-tree
0111-minimum-depth-of-binary-tree
0144-binary-tree-preorder-traversal
0226-invert-binary-tree
0235-lowest-common-ancestor-of-a-binary-search-tree
0236-lowest-common-ancestor-of-a-binary-tree
0257-binary-tree-paths

Divide and Conquer

0053-maximum-subarray
0108-convert-sorted-array-to-binary-search-tree
0169-majority-element
0215-kth-largest-element-in-an-array

Sorting

0075-sort-colors
0169-majority-element
0215-kth-largest-element-in-an-array
0217-contains-duplicate
0229-majority-element-ii
0242-valid-anagram
0349-intersection-of-two-arrays
0350-intersection-of-two-arrays-ii
0389-find-the-difference
0414-third-maximum-number
0455-assign-cookies
0628-maximum-product-of-three-numbers
0645-set-mismatch
1019-squares-of-a-sorted-array
2284-smallest-value-of-the-rearranged-number
2888-minimum-index-of-a-valid-split
3226-minimum-number-game

Heap (Priority Queue)

0215-kth-largest-element-in-an-array
3226-minimum-number-game

Quickselect

0215-kth-largest-element-in-an-array

Two Pointers

0011-container-with-most-water
0026-remove-duplicates-from-sorted-array
0027-remove-element
0028-find-the-index-of-the-first-occurrence-in-a-string
0042-trapping-rain-water
0075-sort-colors
0125-valid-palindrome
0160-intersection-of-two-linked-lists
0189-rotate-array
0234-palindrome-linked-list
0345-reverse-vowels-of-a-string
0349-intersection-of-two-arrays
0350-intersection-of-two-arrays-ii
0392-is-subsequence
0455-assign-cookies
1019-squares-of-a-sorted-array

Greedy

0011-container-with-most-water
0409-longest-palindrome
0455-assign-cookies
0605-can-place-flowers
1818-maximum-score-from-removing-substrings

Hash Table

0001-two-sum
0003-longest-substring-without-repeating-characters
0013-roman-to-integer
0037-sudoku-solver
0160-intersection-of-two-linked-lists
0169-majority-element
0217-contains-duplicate
0219-contains-duplicate-ii
0229-majority-element-ii
0242-valid-anagram
0349-intersection-of-two-arrays
0350-intersection-of-two-arrays-ii
0383-ransom-note
0387-first-unique-character-in-a-string
0389-find-the-difference
0409-longest-palindrome
0448-find-all-numbers-disappeared-in-an-array
0496-next-greater-element-i
0645-set-mismatch
0782-jewels-and-stones
1500-count-largest-group
2888-minimum-index-of-a-valid-split

Queue

0232-implement-queue-using-stacks
0387-first-unique-character-in-a-string

Counting

0169-majority-element
0229-majority-element-ii
0383-ransom-note
0387-first-unique-character-in-a-string

Linked List

0002-add-two-numbers
0083-remove-duplicates-from-sorted-list
0160-intersection-of-two-linked-lists
0206-reverse-linked-list
0234-palindrome-linked-list

Breadth-First Search

0100-same-tree
0101-symmetric-tree
0103-binary-tree-zigzag-level-order-traversal
0104-maximum-depth-of-binary-tree
0111-minimum-depth-of-binary-tree
0226-invert-binary-tree

Dynamic Programming

0022-generate-parentheses
0042-trapping-rain-water
0053-maximum-subarray
0091-decode-ways
0121-best-time-to-buy-and-sell-stock
0131-palindrome-partitioning
0198-house-robber
0392-is-subsequence
1013-fibonacci-number

Sliding Window

0003-longest-substring-without-repeating-characters
0219-contains-duplicate-ii

Matrix

0037-sudoku-solver
0566-reshape-the-matrix

Simulation

0067-add-binary
0258-add-digits
0412-fizz-buzz
0566-reshape-the-matrix
0682-baseball-game
3226-minimum-number-game

Prefix Sum

0238-product-of-array-except-self
0724-find-pivot-index
1603-running-sum-of-1d-array

Math

0002-add-two-numbers
0013-roman-to-integer
0050-powx-n
0066-plus-one
0067-add-binary
0069-sqrtx
0189-rotate-array
0258-add-digits
0412-fizz-buzz
0507-perfect-number
0628-maximum-product-of-three-numbers
1013-fibonacci-number
1500-count-largest-group
2284-smallest-value-of-the-rearranged-number

Recursion

0002-add-two-numbers
0050-powx-n
0206-reverse-linked-list
0234-palindrome-linked-list
1013-fibonacci-number

Stack

0042-trapping-rain-water
0084-largest-rectangle-in-histogram
0094-binary-tree-inorder-traversal
0144-binary-tree-preorder-traversal
0155-min-stack
0232-implement-queue-using-stacks
0234-palindrome-linked-list
0496-next-greater-element-i
0682-baseball-game
1818-maximum-score-from-removing-substrings

String Matching

0028-find-the-index-of-the-first-occurrence-in-a-string

Monotonic Stack

0042-trapping-rain-water
0084-largest-rectangle-in-histogram
0496-next-greater-element-i

Design

0155-min-stack
0232-implement-queue-using-stacks

Bit Manipulation

0067-add-binary
0078-subsets
0136-single-number
0389-find-the-difference
0645-set-mismatch

Backtracking

0022-generate-parentheses
0037-sudoku-solver
0078-subsets
0131-palindrome-partitioning
0257-binary-tree-paths

Memoization

1013-fibonacci-number

Number Theory

0258-add-digits

About

A collection of LeetCode questions to ace the coding interview! - Created using [LeetHub v2](https://github.com/arunbhardwaj/LeetHub-2.0)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published