Skip to content

Latest commit

 

History

2,620 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

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

LeetCode Topics

String

0003-longest-substring-without-repeating-characters
0005-longest-palindromic-substring
0017-letter-combinations-of-a-phone-number
0020-valid-parentheses
0049-group-anagrams
0071-simplify-path
0079-word-search
0091-decode-ways
0093-restore-ip-addresses
0125-valid-palindrome
0139-word-break
0165-compare-version-numbers
0179-largest-number
0227-basic-calculator-ii
0241-different-ways-to-add-parentheses
0242-valid-anagram
0257-binary-tree-paths
0316-remove-duplicate-letters
0331-verify-preorder-serialization-of-a-binary-tree
0344-reverse-string
0383-ransom-note
0387-first-unique-character-in-a-string
0392-is-subsequence
0399-evaluate-division
0402-remove-k-digits
0409-longest-palindrome
0433-minimum-genetic-mutation
0443-string-compression
0449-serialize-and-deserialize-bst
0451-sort-characters-by-frequency
0516-longest-palindromic-subsequence
0524-longest-word-in-dictionary-through-deleting
0567-permutation-in-string
0606-construct-string-from-binary-tree
0647-palindromic-substrings
0678-valid-parenthesis-string
0692-top-k-frequent-words
0721-accounts-merge
0752-open-the-lock
0763-partition-labels
0767-reorganize-string
0784-letter-case-permutation
0844-backspace-string-compare
0856-score-of-parentheses
0921-minimum-add-to-make-parentheses-valid
0981-time-based-key-value-store
0990-satisfiability-of-equality-equations
1021-remove-outermost-parentheses
1047-remove-all-adjacent-duplicates-in-string
1079-letter-tile-possibilities
1081-smallest-subsequence-of-distinct-characters
1208-get-equal-substrings-within-budget
1209-remove-all-adjacent-duplicates-in-string-ii
1239-maximum-length-of-a-concatenated-string-with-unique-characters
1249-minimum-remove-to-make-valid-parentheses
1348-tweet-counts-per-frequency
1456-maximum-number-of-vowels-in-a-substring-of-given-length
1525-number-of-good-ways-to-split-a-string
1541-minimum-insertions-to-balance-a-parentheses-string
1544-make-the-string-great
1614-maximum-nesting-depth-of-the-parentheses
1647-minimum-deletions-to-make-character-frequencies-unique
1769-minimum-number-of-operations-to-move-all-balls-to-each-box
1876-substrings-of-size-three-with-distinct-characters
1963-minimum-number-of-swaps-to-make-the-string-balanced
1985-find-the-kth-largest-integer-in-the-array
2011-final-value-of-variable-after-performing-operations
2055-plates-between-candles
2096-step-by-step-directions-from-a-binary-tree-node-to-another
2269-find-the-k-beauty-of-a-number
2337-move-pieces-to-obtain-a-string
2353-design-a-food-rating-system
2379-minimum-recolors-to-get-k-consecutive-black-blocks
2390-removing-stars-from-a-string
2976-minimum-cost-to-convert-string-i
3090-maximum-length-substring-with-two-occurrences

Stack

0020-valid-parentheses
0042-trapping-rain-water
0071-simplify-path
0094-binary-tree-inorder-traversal
0143-reorder-list
0144-binary-tree-preorder-traversal
0145-binary-tree-postorder-traversal
0150-evaluate-reverse-polish-notation
0173-binary-search-tree-iterator
0227-basic-calculator-ii
0234-palindrome-linked-list
0316-remove-duplicate-letters
0331-verify-preorder-serialization-of-a-binary-tree
0402-remove-k-digits
0445-add-two-numbers-ii
0496-next-greater-element-i
0503-next-greater-element-ii
0589-n-ary-tree-preorder-traversal
0590-n-ary-tree-postorder-traversal
0654-maximum-binary-tree
0678-valid-parenthesis-string
0682-baseball-game
0735-asteroid-collision
0769-max-chunks-to-make-sorted
0844-backspace-string-compare
0853-car-fleet
0856-score-of-parentheses
0897-increasing-order-search-tree
0901-online-stock-span
0921-minimum-add-to-make-parentheses-valid
0946-validate-stack-sequences
1006-clumsy-factorial
1008-construct-binary-search-tree-from-preorder-traversal
1019-next-greater-node-in-linked-list
1021-remove-outermost-parentheses
1047-remove-all-adjacent-duplicates-in-string
1081-smallest-subsequence-of-distinct-characters
1209-remove-all-adjacent-duplicates-in-string-ii
1249-minimum-remove-to-make-valid-parentheses
1441-build-an-array-with-stack-operations
1475-final-prices-with-a-special-discount-in-a-shop
1541-minimum-insertions-to-balance-a-parentheses-string
1544-make-the-string-great
1574-shortest-subarray-to-be-removed-to-make-array-sorted
1614-maximum-nesting-depth-of-the-parentheses
1673-find-the-most-competitive-subsequence
1856-maximum-subarray-min-product
1963-minimum-number-of-swaps-to-make-the-string-balanced
2104-sum-of-subarray-ranges
2130-maximum-twin-sum-of-a-linked-list
2289-steps-to-make-array-non-decreasing
2390-removing-stars-from-a-string
2487-remove-nodes-from-linked-list
2816-double-a-number-represented-as-a-linked-list
2866-beautiful-towers-ii

Array

0001-two-sum
0004-median-of-two-sorted-arrays
0011-container-with-most-water
0015-3sum
0016-3sum-closest
0018-4sum
0026-remove-duplicates-from-sorted-array
0031-next-permutation
0033-search-in-rotated-sorted-array
0034-find-first-and-last-position-of-element-in-sorted-array
0035-search-insert-position
0036-valid-sudoku
0039-combination-sum
0040-combination-sum-ii
0041-first-missing-positive
0042-trapping-rain-water
0045-jump-game-ii
0046-permutations
0047-permutations-ii
0049-group-anagrams
0053-maximum-subarray
0054-spiral-matrix
0055-jump-game
0056-merge-intervals
0059-spiral-matrix-ii
0063-unique-paths-ii
0064-minimum-path-sum
0073-set-matrix-zeroes
0074-search-a-2d-matrix
0075-sort-colors
0078-subsets
0079-word-search
0080-remove-duplicates-from-sorted-array-ii
0081-search-in-rotated-sorted-array-ii
0088-merge-sorted-array
0090-subsets-ii
0105-construct-binary-tree-from-preorder-and-inorder-traversal
0106-construct-binary-tree-from-inorder-and-postorder-traversal
0108-convert-sorted-array-to-binary-search-tree
0120-triangle
0121-best-time-to-buy-and-sell-stock
0128-longest-consecutive-sequence
0134-gas-station
0135-candy
0139-word-break
0150-evaluate-reverse-polish-notation
0152-maximum-product-subarray
0153-find-minimum-in-rotated-sorted-array
0162-find-peak-element
0164-maximum-gap
0167-two-sum-ii-input-array-is-sorted
0169-majority-element
0179-largest-number
0189-rotate-array
0198-house-robber
0200-number-of-islands
0209-minimum-size-subarray-sum
0213-house-robber-ii
0215-kth-largest-element-in-an-array
0216-combination-sum-iii
0217-contains-duplicate
0221-maximal-square
0228-summary-ranges
0229-majority-element-ii
0238-product-of-array-except-self
0240-search-a-2d-matrix-ii
0268-missing-number
0274-h-index
0283-move-zeroes
0287-find-the-duplicate-number
0289-game-of-life
0300-longest-increasing-subsequence
0303-range-sum-query-immutable
0304-range-sum-query-2d-immutable
0309-best-time-to-buy-and-sell-stock-with-cooldown
0313-super-ugly-number
0322-coin-change
0324-wiggle-sort-ii
0334-increasing-triplet-subsequence
0347-top-k-frequent-elements
0349-intersection-of-two-arrays
0350-intersection-of-two-arrays-ii
0373-find-k-pairs-with-smallest-sums
0377-combination-sum-iv
0378-kth-smallest-element-in-a-sorted-matrix
0380-insert-delete-getrandom-o1
0399-evaluate-division
0414-third-maximum-number
0416-partition-equal-subset-sum
0417-pacific-atlantic-water-flow
0435-non-overlapping-intervals
0436-find-right-interval
0442-find-all-duplicates-in-an-array
0448-find-all-numbers-disappeared-in-an-array
0452-minimum-number-of-arrows-to-burst-balloons
0455-assign-cookies
0462-minimum-moves-to-equal-array-elements-ii
0485-max-consecutive-ones
0491-non-decreasing-subsequences
0494-target-sum
0496-next-greater-element-i
0503-next-greater-element-ii
0518-coin-change-ii
0524-longest-word-in-dictionary-through-deleting
0525-contiguous-array
0526-beautiful-arrangement
0542-01-matrix
0560-subarray-sum-equals-k
0561-array-partition
0565-array-nesting
0566-reshape-the-matrix
0611-valid-triangle-number
0621-task-scheduler
0643-maximum-average-subarray-i
0645-set-mismatch
0646-maximum-length-of-pair-chain
0654-maximum-binary-tree
0665-non-decreasing-array
0673-number-of-longest-increasing-subsequence
0682-baseball-game
0690-employee-importance
0692-top-k-frequent-words
0695-max-area-of-island
0704-binary-search
0713-subarray-product-less-than-k
0714-best-time-to-buy-and-sell-stock-with-transaction-fee
0721-accounts-merge
0724-find-pivot-index
0729-my-calendar-i
0733-flood-fill
0735-asteroid-collision
0740-delete-and-earn
0744-find-smallest-letter-greater-than-target
0746-min-cost-climbing-stairs
0752-open-the-lock
0766-toeplitz-matrix
0769-max-chunks-to-make-sorted
0781-rabbits-in-forest
0786-k-th-smallest-prime-fraction
0853-car-fleet
0860-lemonade-change
0881-boats-to-save-people
0889-construct-binary-tree-from-preorder-and-postorder-traversal
0904-fruit-into-baskets
0905-sort-array-by-parity
0909-snakes-and-ladders
0911-online-election
0912-sort-an-array
0918-maximum-sum-circular-subarray
0922-sort-array-by-parity-ii
0941-valid-mountain-array
0946-validate-stack-sequences
0973-k-closest-points-to-origin
0974-subarray-sums-divisible-by-k
0977-squares-of-a-sorted-array
0983-minimum-cost-for-tickets
0986-interval-list-intersections
0990-satisfiability-of-equality-equations
0994-rotting-oranges
0997-find-the-town-judge
1004-max-consecutive-ones-iii
1005-maximize-sum-of-array-after-k-negations
1008-construct-binary-search-tree-from-preorder-traversal
1011-capacity-to-ship-packages-within-d-days
1014-best-sightseeing-pair
1019-next-greater-node-in-linked-list
1024-video-stitching
1029-two-city-scheduling
1046-last-stone-weight
1052-grumpy-bookstore-owner
1054-distant-barcodes
1091-shortest-path-in-binary-matrix
1094-car-pooling
1109-corporate-flight-bookings
1122-relative-sort-array
1162-as-far-from-land-as-possible
1207-unique-number-of-occurrences
1218-longest-arithmetic-subsequence-of-given-difference
1239-maximum-length-of-a-concatenated-string-with-unique-characters
1248-count-number-of-nice-subarrays
1277-count-square-submatrices-with-all-ones
1283-find-the-smallest-divisor-given-a-threshold
1288-remove-covered-intervals
1310-xor-queries-of-a-subarray
1331-rank-transform-of-an-array
1337-the-k-weakest-rows-in-a-matrix
1343-number-of-sub-arrays-of-size-k-and-average-greater-than-or-equal-to-threshold
1353-maximum-number-of-events-that-can-be-attended
1395-count-number-of-teams
1423-maximum-points-you-can-obtain-from-cards
1438-longest-continuous-subarray-with-absolute-diff-less-than-or-equal-to-limit
1441-build-an-array-with-stack-operations
1475-final-prices-with-a-special-discount-in-a-shop
1482-minimum-number-of-days-to-make-m-bouquets
1493-longest-subarray-of-1s-after-deleting-one-element
1514-path-with-maximum-probability
1572-matrix-diagonal-sum
1574-shortest-subarray-to-be-removed-to-make-array-sorted
1584-min-cost-to-connect-all-points
1630-arithmetic-subarrays
1631-path-with-minimum-effort
1642-furthest-building-you-can-reach
1646-get-maximum-in-generated-array
1654-minimum-jumps-to-reach-home
1673-find-the-most-competitive-subsequence
1710-maximum-units-on-a-truck
1720-decode-xored-array
1732-find-the-highest-altitude
1734-decode-xored-permutation
1749-maximum-absolute-sum-of-any-subarray
1752-check-if-array-is-sorted-and-rotated
1765-map-of-highest-peak
1769-minimum-number-of-operations-to-move-all-balls-to-each-box
1824-minimum-sideway-jumps
1833-maximum-ice-cream-bars
1834-single-threaded-cpu
1854-maximum-population-year
1856-maximum-subarray-min-product
1861-rotating-the-box
1863-sum-of-all-subset-xor-totals
1870-minimum-speed-to-arrive-on-time
1882-process-tasks-using-servers
1893-check-if-all-the-integers-in-a-range-are-covered
1926-nearest-exit-from-entrance-in-maze
1937-maximum-number-of-points-with-cost
1942-the-number-of-the-smallest-unoccupied-chair
1943-describe-the-painting
1985-find-the-kth-largest-integer-in-the-array
1991-find-the-middle-index-in-array
2011-final-value-of-variable-after-performing-operations
2012-sum-of-beauty-in-the-array
2016-maximum-difference-between-increasing-elements
2055-plates-between-candles
2059-minimum-operations-to-convert-number
2080-range-frequency-queries
2099-find-subsequence-of-length-k-with-the-largest-sum
2100-find-good-days-to-rob-the-bank
2104-sum-of-subarray-ranges
2140-solving-questions-with-brainpower
2161-partition-array-according-to-given-pivot
2187-minimum-time-to-complete-trips
2196-create-binary-tree-from-descriptions
2256-minimum-average-difference
2279-maximum-bags-with-full-capacity-of-rocks
2289-steps-to-make-array-non-decreasing
2294-partition-array-such-that-maximum-difference-is-k
2300-successful-pairs-of-spells-and-potions
2335-minimum-amount-of-time-to-fill-cups
2353-design-a-food-rating-system
2369-check-if-there-is-a-valid-partition-for-the-array
2406-divide-intervals-into-minimum-number-of-groups
2558-take-gifts-from-the-richest-pile
2563-count-the-number-of-fair-pairs
2574-left-and-right-sum-differences
2597-the-number-of-beautiful-subsets
2762-continuous-subarrays
2848-points-that-intersect-with-cars
2866-beautiful-towers-ii
2976-minimum-cost-to-convert-string-i
3074-apple-redistribution-into-boxes
3286-find-a-safe-walk-through-a-grid

Dynamic Programming

0005-longest-palindromic-substring
0042-trapping-rain-water
0045-jump-game-ii
0053-maximum-subarray
0055-jump-game
0063-unique-paths-ii
0064-minimum-path-sum
0070-climbing-stairs
0091-decode-ways
0120-triangle
0121-best-time-to-buy-and-sell-stock
0139-word-break
0152-maximum-product-subarray
0198-house-robber
0213-house-robber-ii
0221-maximal-square
0241-different-ways-to-add-parentheses
0264-ugly-number-ii
0279-perfect-squares
0300-longest-increasing-subsequence
0309-best-time-to-buy-and-sell-stock-with-cooldown
0313-super-ugly-number
0322-coin-change
0337-house-robber-iii
0377-combination-sum-iv
0392-is-subsequence
0416-partition-equal-subset-sum
0435-non-overlapping-intervals
0494-target-sum
0509-fibonacci-number
0516-longest-palindromic-subsequence
0518-coin-change-ii
0526-beautiful-arrangement
0542-01-matrix
0646-maximum-length-of-pair-chain
0647-palindromic-substrings
0673-number-of-longest-increasing-subsequence
0678-valid-parenthesis-string
0714-best-time-to-buy-and-sell-stock-with-transaction-fee
0740-delete-and-earn
0746-min-cost-climbing-stairs
0787-cheapest-flights-within-k-stops
0918-maximum-sum-circular-subarray
0983-minimum-cost-for-tickets
1014-best-sightseeing-pair
1024-video-stitching
1137-n-th-tribonacci-number
1162-as-far-from-land-as-possible
1218-longest-arithmetic-subsequence-of-given-difference
1277-count-square-submatrices-with-all-ones
1334-find-the-city-with-the-smallest-number-of-neighbors-at-a-threshold-distance
1372-longest-zigzag-path-in-a-binary-tree
1395-count-number-of-teams
1493-longest-subarray-of-1s-after-deleting-one-element
1525-number-of-good-ways-to-split-a-string
1749-maximum-absolute-sum-of-any-subarray
1824-minimum-sideway-jumps
1937-maximum-number-of-points-with-cost
1976-number-of-ways-to-arrive-at-destination
2100-find-good-days-to-rob-the-bank
2140-solving-questions-with-brainpower
2289-steps-to-make-array-non-decreasing
2369-check-if-there-is-a-valid-partition-for-the-array
2597-the-number-of-beautiful-subsets

Hash Table

0001-two-sum
0003-longest-substring-without-repeating-characters
0017-letter-combinations-of-a-phone-number
0036-valid-sudoku
0041-first-missing-positive
0049-group-anagrams
0073-set-matrix-zeroes
0105-construct-binary-tree-from-preorder-and-inorder-traversal
0106-construct-binary-tree-from-inorder-and-postorder-traversal
0128-longest-consecutive-sequence
0133-clone-graph
0139-word-break
0142-linked-list-cycle-ii
0169-majority-element
0202-happy-number
0217-contains-duplicate
0229-majority-element-ii
0242-valid-anagram
0264-ugly-number-ii
0268-missing-number
0347-top-k-frequent-elements
0349-intersection-of-two-arrays
0350-intersection-of-two-arrays-ii
0380-insert-delete-getrandom-o1
0383-ransom-note
0387-first-unique-character-in-a-string
0409-longest-palindrome
0433-minimum-genetic-mutation
0442-find-all-duplicates-in-an-array
0448-find-all-numbers-disappeared-in-an-array
0451-sort-characters-by-frequency
0491-non-decreasing-subsequences
0496-next-greater-element-i
0525-contiguous-array
0560-subarray-sum-equals-k
0567-permutation-in-string
0621-task-scheduler
0645-set-mismatch
0690-employee-importance
0692-top-k-frequent-words
0721-accounts-merge
0740-delete-and-earn
0752-open-the-lock
0763-partition-labels
0767-reorganize-string
0781-rabbits-in-forest
0865-smallest-subtree-with-all-the-deepest-nodes
0889-construct-binary-tree-from-preorder-and-postorder-traversal
0904-fruit-into-baskets
0911-online-election
0947-most-stones-removed-with-same-row-or-column
0974-subarray-sums-divisible-by-k
0981-time-based-key-value-store
0997-find-the-town-judge
1054-distant-barcodes
1079-letter-tile-possibilities
1122-relative-sort-array
1123-lowest-common-ancestor-of-deepest-leaves
1171-remove-zero-sum-consecutive-nodes-from-linked-list
1207-unique-number-of-occurrences
1218-longest-arithmetic-subsequence-of-given-difference
1248-count-number-of-nice-subarrays
1331-rank-transform-of-an-array
1348-tweet-counts-per-frequency
1525-number-of-good-ways-to-split-a-string
1630-arithmetic-subarrays
1647-minimum-deletions-to-make-character-frequencies-unique
1654-minimum-jumps-to-reach-home
1876-substrings-of-size-three-with-distinct-characters
1893-check-if-all-the-integers-in-a-range-are-covered
1942-the-number-of-the-smallest-unoccupied-chair
1943-describe-the-painting
2034-stock-price-fluctuation
2080-range-frequency-queries
2099-find-subsequence-of-length-k-with-the-largest-sum
2196-create-binary-tree-from-descriptions
2349-design-a-number-container-system
2353-design-a-food-rating-system
2597-the-number-of-beautiful-subsets
2848-points-that-intersect-with-cars
3090-maximum-length-substring-with-two-occurrences

Sliding Window

0003-longest-substring-without-repeating-characters
0209-minimum-size-subarray-sum
0567-permutation-in-string
0643-maximum-average-subarray-i
0713-subarray-product-less-than-k
0904-fruit-into-baskets
1004-max-consecutive-ones-iii
1052-grumpy-bookstore-owner
1208-get-equal-substrings-within-budget
1248-count-number-of-nice-subarrays
1343-number-of-sub-arrays-of-size-k-and-average-greater-than-or-equal-to-threshold
1423-maximum-points-you-can-obtain-from-cards
1438-longest-continuous-subarray-with-absolute-diff-less-than-or-equal-to-limit
1456-maximum-number-of-vowels-in-a-substring-of-given-length
1493-longest-subarray-of-1s-after-deleting-one-element
1876-substrings-of-size-three-with-distinct-characters
2269-find-the-k-beauty-of-a-number
2379-minimum-recolors-to-get-k-consecutive-black-blocks
2762-continuous-subarrays
3090-maximum-length-substring-with-two-occurrences

Sorting

0015-3sum
0016-3sum-closest
0018-4sum
0047-permutations-ii
0049-group-anagrams
0056-merge-intervals
0075-sort-colors
0088-merge-sorted-array
0147-insertion-sort-list
0148-sort-list
0164-maximum-gap
0169-majority-element
0179-largest-number
0215-kth-largest-element-in-an-array
0217-contains-duplicate
0229-majority-element-ii
0242-valid-anagram
0268-missing-number
0274-h-index
0295-find-median-from-data-stream
0324-wiggle-sort-ii
0347-top-k-frequent-elements
0349-intersection-of-two-arrays
0350-intersection-of-two-arrays-ii
0378-kth-smallest-element-in-a-sorted-matrix
0414-third-maximum-number
0435-non-overlapping-intervals
0436-find-right-interval
0442-find-all-duplicates-in-an-array
0451-sort-characters-by-frequency
0452-minimum-number-of-arrows-to-burst-balloons
0455-assign-cookies
0462-minimum-moves-to-equal-array-elements-ii
0524-longest-word-in-dictionary-through-deleting
0561-array-partition
0611-valid-triangle-number
0621-task-scheduler
0645-set-mismatch
0646-maximum-length-of-pair-chain
0692-top-k-frequent-words
0721-accounts-merge
0767-reorganize-string
0769-max-chunks-to-make-sorted
0786-k-th-smallest-prime-fraction
0853-car-fleet
0881-boats-to-save-people
0905-sort-array-by-parity
0912-sort-an-array
0922-sort-array-by-parity-ii
0973-k-closest-points-to-origin
0977-squares-of-a-sorted-array
1005-maximize-sum-of-array-after-k-negations
1029-two-city-scheduling
1054-distant-barcodes
1094-car-pooling
1122-relative-sort-array
1288-remove-covered-intervals
1331-rank-transform-of-an-array
1337-the-k-weakest-rows-in-a-matrix
1348-tweet-counts-per-frequency
1353-maximum-number-of-events-that-can-be-attended
1630-arithmetic-subarrays
1647-minimum-deletions-to-make-character-frequencies-unique
1710-maximum-units-on-a-truck
1833-maximum-ice-cream-bars
1834-single-threaded-cpu
1943-describe-the-painting
1985-find-the-kth-largest-integer-in-the-array
2099-find-subsequence-of-length-k-with-the-largest-sum
2279-maximum-bags-with-full-capacity-of-rocks
2294-partition-array-such-that-maximum-difference-is-k
2300-successful-pairs-of-spells-and-potions
2335-minimum-amount-of-time-to-fill-cups
2406-divide-intervals-into-minimum-number-of-groups
2563-count-the-number-of-fair-pairs
2597-the-number-of-beautiful-subsets
3074-apple-redistribution-into-boxes

Depth-First Search

0079-word-search
0094-binary-tree-inorder-traversal
0098-validate-binary-search-tree
0099-recover-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
0112-path-sum
0113-path-sum-ii
0129-sum-root-to-leaf-numbers
0133-clone-graph
0144-binary-tree-preorder-traversal
0145-binary-tree-postorder-traversal
0199-binary-tree-right-side-view
0200-number-of-islands
0207-course-schedule
0210-course-schedule-ii
0226-invert-binary-tree
0230-kth-smallest-element-in-a-bst
0235-lowest-common-ancestor-of-a-binary-search-tree
0236-lowest-common-ancestor-of-a-binary-tree
0257-binary-tree-paths
0310-minimum-height-trees
0337-house-robber-iii
0399-evaluate-division
0404-sum-of-left-leaves
0417-pacific-atlantic-water-flow
0449-serialize-and-deserialize-bst
0501-find-mode-in-binary-search-tree
0513-find-bottom-left-tree-value
0515-find-largest-value-in-each-tree-row
0530-minimum-absolute-difference-in-bst
0538-convert-bst-to-greater-tree
0543-diameter-of-binary-tree
0547-number-of-provinces
0559-maximum-depth-of-n-ary-tree
0563-binary-tree-tilt
0565-array-nesting
0572-subtree-of-another-tree
0589-n-ary-tree-preorder-traversal
0590-n-ary-tree-postorder-traversal
0606-construct-string-from-binary-tree
0617-merge-two-binary-trees
0637-average-of-levels-in-binary-tree
0662-maximum-width-of-binary-tree
0684-redundant-connection
0687-longest-univalue-path
0690-employee-importance
0695-max-area-of-island
0721-accounts-merge
0733-flood-fill
0743-network-delay-time
0783-minimum-distance-between-bst-nodes
0785-is-graph-bipartite
0787-cheapest-flights-within-k-stops
0802-find-eventual-safe-states
0841-keys-and-rooms
0865-smallest-subtree-with-all-the-deepest-nodes
0886-possible-bipartition
0897-increasing-order-search-tree
0938-range-sum-of-bst
0947-most-stones-removed-with-same-row-or-column
0979-distribute-coins-in-binary-tree
0993-cousins-in-binary-tree
1022-sum-of-root-to-leaf-binary-numbers
1123-lowest-common-ancestor-of-deepest-leaves
1161-maximum-level-sum-of-a-binary-tree
1315-sum-of-nodes-with-even-valued-grandparent
1319-number-of-operations-to-make-network-connected
1372-longest-zigzag-path-in-a-binary-tree
1382-balance-a-binary-search-tree
1448-count-good-nodes-in-binary-tree
1462-course-schedule-iv
1466-reorder-routes-to-make-all-paths-lead-to-the-city-zero
1631-path-with-minimum-effort
1971-find-if-path-exists-in-graph
2096-step-by-step-directions-from-a-binary-tree-node-to-another
2415-reverse-odd-levels-of-binary-tree

Breadth-First Search

0100-same-tree
0101-symmetric-tree
0102-binary-tree-level-order-traversal
0104-maximum-depth-of-binary-tree
0107-binary-tree-level-order-traversal-ii
0111-minimum-depth-of-binary-tree
0112-path-sum
0133-clone-graph
0199-binary-tree-right-side-view
0200-number-of-islands
0207-course-schedule
0210-course-schedule-ii
0226-invert-binary-tree
0279-perfect-squares
0310-minimum-height-trees
0322-coin-change
0399-evaluate-division
0404-sum-of-left-leaves
0417-pacific-atlantic-water-flow
0429-n-ary-tree-level-order-traversal
0433-minimum-genetic-mutation
0449-serialize-and-deserialize-bst
0513-find-bottom-left-tree-value
0515-find-largest-value-in-each-tree-row
0530-minimum-absolute-difference-in-bst
0542-01-matrix
0547-number-of-provinces
0559-maximum-depth-of-n-ary-tree
0617-merge-two-binary-trees
0637-average-of-levels-in-binary-tree
0662-maximum-width-of-binary-tree
0684-redundant-connection
0690-employee-importance
0695-max-area-of-island
0721-accounts-merge
0733-flood-fill
0743-network-delay-time
0752-open-the-lock
0783-minimum-distance-between-bst-nodes
0785-is-graph-bipartite
0787-cheapest-flights-within-k-stops
0802-find-eventual-safe-states
0841-keys-and-rooms
0865-smallest-subtree-with-all-the-deepest-nodes
0886-possible-bipartition
0909-snakes-and-ladders
0993-cousins-in-binary-tree
0994-rotting-oranges
1091-shortest-path-in-binary-matrix
1123-lowest-common-ancestor-of-deepest-leaves
1129-shortest-path-with-alternating-colors
1161-maximum-level-sum-of-a-binary-tree
1162-as-far-from-land-as-possible
1315-sum-of-nodes-with-even-valued-grandparent
1319-number-of-operations-to-make-network-connected
1448-count-good-nodes-in-binary-tree
1462-course-schedule-iv
1466-reorder-routes-to-make-all-paths-lead-to-the-city-zero
1609-even-odd-tree
1631-path-with-minimum-effort
1654-minimum-jumps-to-reach-home
1765-map-of-highest-peak
1926-nearest-exit-from-entrance-in-maze
1971-find-if-path-exists-in-graph
2059-minimum-operations-to-convert-number
2415-reverse-odd-levels-of-binary-tree
3286-find-a-safe-walk-through-a-grid

Union-Find

0128-longest-consecutive-sequence
0200-number-of-islands
0399-evaluate-division
0547-number-of-provinces
0684-redundant-connection
0695-max-area-of-island
0721-accounts-merge
0785-is-graph-bipartite
0886-possible-bipartition
0947-most-stones-removed-with-same-row-or-column
0990-satisfiability-of-equality-equations
1319-number-of-operations-to-make-network-connected
1584-min-cost-to-connect-all-points
1631-path-with-minimum-effort
1971-find-if-path-exists-in-graph

Matrix

0036-valid-sudoku
0054-spiral-matrix
0059-spiral-matrix-ii
0063-unique-paths-ii
0064-minimum-path-sum
0073-set-matrix-zeroes
0074-search-a-2d-matrix
0079-word-search
0200-number-of-islands
0221-maximal-square
0240-search-a-2d-matrix-ii
0289-game-of-life
0304-range-sum-query-2d-immutable
0378-kth-smallest-element-in-a-sorted-matrix
0417-pacific-atlantic-water-flow
0542-01-matrix
0566-reshape-the-matrix
0695-max-area-of-island
0733-flood-fill
0766-toeplitz-matrix
0909-snakes-and-ladders
0994-rotting-oranges
1091-shortest-path-in-binary-matrix
1162-as-far-from-land-as-possible
1277-count-square-submatrices-with-all-ones
1337-the-k-weakest-rows-in-a-matrix
1572-matrix-diagonal-sum
1631-path-with-minimum-effort
1765-map-of-highest-peak
1861-rotating-the-box
1926-nearest-exit-from-entrance-in-maze
1937-maximum-number-of-points-with-cost
3286-find-a-safe-walk-through-a-grid

Graph Theory

0133-clone-graph
0207-course-schedule
0210-course-schedule-ii
0310-minimum-height-trees
0399-evaluate-division
0547-number-of-provinces
0684-redundant-connection
0743-network-delay-time
0785-is-graph-bipartite
0787-cheapest-flights-within-k-stops
0802-find-eventual-safe-states
0841-keys-and-rooms
0886-possible-bipartition
0947-most-stones-removed-with-same-row-or-column
0990-satisfiability-of-equality-equations
0997-find-the-town-judge
1129-shortest-path-with-alternating-colors
1319-number-of-operations-to-make-network-connected
1334-find-the-city-with-the-smallest-number-of-neighbors-at-a-threshold-distance
1462-course-schedule-iv
1466-reorder-routes-to-make-all-paths-lead-to-the-city-zero
1514-path-with-maximum-probability
1557-minimum-number-of-vertices-to-reach-all-nodes
1584-min-cost-to-connect-all-points
1615-maximal-network-rank
1791-find-center-of-star-graph
1971-find-if-path-exists-in-graph
1976-number-of-ways-to-arrive-at-destination
2976-minimum-cost-to-convert-string-i
3286-find-a-safe-walk-through-a-grid

Topological Sort

0207-course-schedule
0210-course-schedule-ii
0310-minimum-height-trees
0802-find-eventual-safe-states
1462-course-schedule-iv
1976-number-of-ways-to-arrive-at-destination

Divide and Conquer

0004-median-of-two-sorted-arrays
0023-merge-k-sorted-lists
0053-maximum-subarray
0105-construct-binary-tree-from-preorder-and-inorder-traversal
0106-construct-binary-tree-from-inorder-and-postorder-traversal
0108-convert-sorted-array-to-binary-search-tree
0109-convert-sorted-list-to-binary-search-tree
0148-sort-list
0169-majority-element
0215-kth-largest-element-in-an-array
0240-search-a-2d-matrix-ii
0324-wiggle-sort-ii
0347-top-k-frequent-elements
0654-maximum-binary-tree
0889-construct-binary-tree-from-preorder-and-postorder-traversal
0912-sort-an-array
0918-maximum-sum-circular-subarray
0973-k-closest-points-to-origin
1382-balance-a-binary-search-tree
1985-find-the-kth-largest-integer-in-the-array

Heap (Priority Queue)

0023-merge-k-sorted-lists
0215-kth-largest-element-in-an-array
0264-ugly-number-ii
0295-find-median-from-data-stream
0347-top-k-frequent-elements
0373-find-k-pairs-with-smallest-sums
0378-kth-smallest-element-in-a-sorted-matrix
0451-sort-characters-by-frequency
0621-task-scheduler
0692-top-k-frequent-words
0703-kth-largest-element-in-a-stream
0743-network-delay-time
0767-reorganize-string
0786-k-th-smallest-prime-fraction
0787-cheapest-flights-within-k-stops
0912-sort-an-array
0973-k-closest-points-to-origin
1046-last-stone-weight
1054-distant-barcodes
1094-car-pooling
1337-the-k-weakest-rows-in-a-matrix
1353-maximum-number-of-events-that-can-be-attended
1438-longest-continuous-subarray-with-absolute-diff-less-than-or-equal-to-limit
1514-path-with-maximum-probability
1631-path-with-minimum-effort
1642-furthest-building-you-can-reach
1834-single-threaded-cpu
1882-process-tasks-using-servers
1942-the-number-of-the-smallest-unoccupied-chair
1985-find-the-kth-largest-integer-in-the-array
2034-stock-price-fluctuation
2099-find-subsequence-of-length-k-with-the-largest-sum
2335-minimum-amount-of-time-to-fill-cups
2349-design-a-number-container-system
2353-design-a-food-rating-system
2406-divide-intervals-into-minimum-number-of-groups
2558-take-gifts-from-the-richest-pile
2762-continuous-subarrays
3286-find-a-safe-walk-through-a-grid

Quickselect

0215-kth-largest-element-in-an-array
0324-wiggle-sort-ii
0347-top-k-frequent-elements
0973-k-closest-points-to-origin
1985-find-the-kth-largest-integer-in-the-array

Two Pointers

0005-longest-palindromic-substring
0011-container-with-most-water
0015-3sum
0016-3sum-closest
0018-4sum
0019-remove-nth-node-from-end-of-list
0026-remove-duplicates-from-sorted-array
0031-next-permutation
0042-trapping-rain-water
0061-rotate-list
0075-sort-colors
0080-remove-duplicates-from-sorted-array-ii
0082-remove-duplicates-from-sorted-list-ii
0086-partition-list
0088-merge-sorted-array
0125-valid-palindrome
0142-linked-list-cycle-ii
0143-reorder-list
0148-sort-list
0165-compare-version-numbers
0167-two-sum-ii-input-array-is-sorted
0189-rotate-array
0202-happy-number
0234-palindrome-linked-list
0283-move-zeroes
0287-find-the-duplicate-number
0295-find-median-from-data-stream
0344-reverse-string
0349-intersection-of-two-arrays
0350-intersection-of-two-arrays-ii
0392-is-subsequence
0443-string-compression
0455-assign-cookies
0524-longest-word-in-dictionary-through-deleting
0567-permutation-in-string
0611-valid-triangle-number
0633-sum-of-square-numbers
0647-palindromic-substrings
0763-partition-labels
0786-k-th-smallest-prime-fraction
0844-backspace-string-compare
0881-boats-to-save-people
0905-sort-array-by-parity
0922-sort-array-by-parity-ii
0977-squares-of-a-sorted-array
0986-interval-list-intersections
1574-shortest-subarray-to-be-removed-to-make-array-sorted
1721-swapping-nodes-in-a-linked-list
1861-rotating-the-box
1963-minimum-number-of-swaps-to-make-the-string-balanced
2095-delete-the-middle-node-of-a-linked-list
2130-maximum-twin-sum-of-a-linked-list
2161-partition-array-according-to-given-pivot
2300-successful-pairs-of-spells-and-potions
2337-move-pieces-to-obtain-a-string
2406-divide-intervals-into-minimum-number-of-groups
2563-count-the-number-of-fair-pairs

Design

0173-binary-search-tree-iterator
0295-find-median-from-data-stream
0303-range-sum-query-immutable
0304-range-sum-query-2d-immutable
0380-insert-delete-getrandom-o1
0449-serialize-and-deserialize-bst
0703-kth-largest-element-in-a-stream
0729-my-calendar-i
0901-online-stock-span
0911-online-election
0981-time-based-key-value-store
1348-tweet-counts-per-frequency
2034-stock-price-fluctuation
2080-range-frequency-queries
2349-design-a-number-container-system
2353-design-a-food-rating-system

Data Stream

0295-find-median-from-data-stream
0703-kth-largest-element-in-a-stream
0901-online-stock-span
2034-stock-price-fluctuation

Monotonic Stack

0042-trapping-rain-water
0316-remove-duplicate-letters
0402-remove-k-digits
0496-next-greater-element-i
0503-next-greater-element-ii
0654-maximum-binary-tree
0769-max-chunks-to-make-sorted
0853-car-fleet
0901-online-stock-span
1008-construct-binary-search-tree-from-preorder-traversal
1019-next-greater-node-in-linked-list
1081-smallest-subsequence-of-distinct-characters
1475-final-prices-with-a-special-discount-in-a-shop
1574-shortest-subarray-to-be-removed-to-make-array-sorted
1673-find-the-most-competitive-subsequence
1856-maximum-subarray-min-product
2104-sum-of-subarray-ranges
2289-steps-to-make-array-non-decreasing
2487-remove-nodes-from-linked-list
2866-beautiful-towers-ii

Binary Search

0004-median-of-two-sorted-arrays
0033-search-in-rotated-sorted-array
0034-find-first-and-last-position-of-element-in-sorted-array
0035-search-insert-position
0069-sqrtx
0074-search-a-2d-matrix
0081-search-in-rotated-sorted-array-ii
0153-find-minimum-in-rotated-sorted-array
0162-find-peak-element
0167-two-sum-ii-input-array-is-sorted
0209-minimum-size-subarray-sum
0240-search-a-2d-matrix-ii
0268-missing-number
0278-first-bad-version
0287-find-the-duplicate-number
0300-longest-increasing-subsequence
0349-intersection-of-two-arrays
0350-intersection-of-two-arrays-ii
0374-guess-number-higher-or-lower
0378-kth-smallest-element-in-a-sorted-matrix
0436-find-right-interval
0441-arranging-coins
0611-valid-triangle-number
0633-sum-of-square-numbers
0704-binary-search
0713-subarray-product-less-than-k
0729-my-calendar-i
0744-find-smallest-letter-greater-than-target
0786-k-th-smallest-prime-fraction
0911-online-election
0981-time-based-key-value-store
1004-max-consecutive-ones-iii
1011-capacity-to-ship-packages-within-d-days
1208-get-equal-substrings-within-budget
1283-find-the-smallest-divisor-given-a-threshold
1337-the-k-weakest-rows-in-a-matrix
1348-tweet-counts-per-frequency
1482-minimum-number-of-days-to-make-m-bouquets
1574-shortest-subarray-to-be-removed-to-make-array-sorted
1631-path-with-minimum-effort
1870-minimum-speed-to-arrive-on-time
2055-plates-between-candles
2080-range-frequency-queries
2187-minimum-time-to-complete-trips
2300-successful-pairs-of-spells-and-potions
2563-count-the-number-of-fair-pairs

Math

0002-add-two-numbers
0069-sqrtx
0070-climbing-stairs
0150-evaluate-reverse-polish-notation
0189-rotate-array
0202-happy-number
0227-basic-calculator-ii
0241-different-ways-to-add-parentheses
0264-ugly-number-ii
0268-missing-number
0279-perfect-squares
0313-super-ugly-number
0380-insert-delete-getrandom-o1
0441-arranging-coins
0445-add-two-numbers-ii
0462-minimum-moves-to-equal-array-elements-ii
0509-fibonacci-number
0633-sum-of-square-numbers
0781-rabbits-in-forest
0973-k-closest-points-to-origin
1006-clumsy-factorial
1137-n-th-tribonacci-number
1248-count-number-of-nice-subarrays
1863-sum-of-all-subset-xor-totals
2269-find-the-k-beauty-of-a-number
2597-the-number-of-beautiful-subsets
2816-double-a-number-represented-as-a-linked-list

Randomized

0380-insert-delete-getrandom-o1

Bucket Sort

0164-maximum-gap
0347-top-k-frequent-elements
0451-sort-characters-by-frequency
0692-top-k-frequent-words
0912-sort-an-array

Radix Sort

0164-maximum-gap
0912-sort-an-array

Linked List

0002-add-two-numbers
0019-remove-nth-node-from-end-of-list
0021-merge-two-sorted-lists
0023-merge-k-sorted-lists
0024-swap-nodes-in-pairs
0061-rotate-list
0082-remove-duplicates-from-sorted-list-ii
0083-remove-duplicates-from-sorted-list
0086-partition-list
0092-reverse-linked-list-ii
0109-convert-sorted-list-to-binary-search-tree
0142-linked-list-cycle-ii
0143-reorder-list
0147-insertion-sort-list
0148-sort-list
0203-remove-linked-list-elements
0206-reverse-linked-list
0234-palindrome-linked-list
0445-add-two-numbers-ii
1019-next-greater-node-in-linked-list
1171-remove-zero-sum-consecutive-nodes-from-linked-list
1669-merge-in-between-linked-lists
1721-swapping-nodes-in-a-linked-list
2074-reverse-nodes-in-even-length-groups
2095-delete-the-middle-node-of-a-linked-list
2130-maximum-twin-sum-of-a-linked-list
2181-merge-nodes-in-between-zeros
2289-steps-to-make-array-non-decreasing
2487-remove-nodes-from-linked-list
2816-double-a-number-represented-as-a-linked-list

Merge Sort

0023-merge-k-sorted-lists
0148-sort-list
0912-sort-an-array

Memoization

0070-climbing-stairs
0139-word-break
0241-different-ways-to-add-parentheses
0509-fibonacci-number
1137-n-th-tribonacci-number

Greedy

0011-container-with-most-water
0045-jump-game-ii
0055-jump-game
0134-gas-station
0135-candy
0179-largest-number
0316-remove-duplicate-letters
0324-wiggle-sort-ii
0334-increasing-triplet-subsequence
0402-remove-k-digits
0409-longest-palindrome
0435-non-overlapping-intervals
0452-minimum-number-of-arrows-to-burst-balloons
0455-assign-cookies
0561-array-partition
0611-valid-triangle-number
0621-task-scheduler
0646-maximum-length-of-pair-chain
0678-valid-parenthesis-string
0714-best-time-to-buy-and-sell-stock-with-transaction-fee
0763-partition-labels
0767-reorganize-string
0769-max-chunks-to-make-sorted
0781-rabbits-in-forest
0860-lemonade-change
0881-boats-to-save-people
0921-minimum-add-to-make-parentheses-valid
1005-maximize-sum-of-array-after-k-negations
1024-video-stitching
1029-two-city-scheduling
1054-distant-barcodes
1081-smallest-subsequence-of-distinct-characters
1353-maximum-number-of-events-that-can-be-attended
1382-balance-a-binary-search-tree
1541-minimum-insertions-to-balance-a-parentheses-string
1642-furthest-building-you-can-reach
1647-minimum-deletions-to-make-character-frequencies-unique
1673-find-the-most-competitive-subsequence
1710-maximum-units-on-a-truck
1824-minimum-sideway-jumps
1833-maximum-ice-cream-bars
1963-minimum-number-of-swaps-to-make-the-string-balanced
2279-maximum-bags-with-full-capacity-of-rocks
2294-partition-array-such-that-maximum-difference-is-k
2335-minimum-amount-of-time-to-fill-cups
2406-divide-intervals-into-minimum-number-of-groups
3074-apple-redistribution-into-boxes

Counting

0169-majority-element
0229-majority-element-ii
0347-top-k-frequent-elements
0383-ransom-note
0387-first-unique-character-in-a-string
0451-sort-characters-by-frequency
0621-task-scheduler
0692-top-k-frequent-words
0767-reorganize-string
1054-distant-barcodes
1079-letter-tile-possibilities
1854-maximum-population-year
1876-substrings-of-size-three-with-distinct-characters

Bit Manipulation

0078-subsets
0090-subsets-ii
0268-missing-number
0287-find-the-duplicate-number
0491-non-decreasing-subsequences
0526-beautiful-arrangement
0645-set-mismatch
0784-letter-case-permutation
1239-maximum-length-of-a-concatenated-string-with-unique-characters
1310-xor-queries-of-a-subarray
1525-number-of-good-ways-to-split-a-string
1720-decode-xored-array
1734-decode-xored-permutation
1863-sum-of-all-subset-xor-totals

Shortest Path

0399-evaluate-division
0743-network-delay-time
0787-cheapest-flights-within-k-stops
1334-find-the-city-with-the-smallest-number-of-neighbors-at-a-threshold-distance
1514-path-with-maximum-probability
1976-number-of-ways-to-arrive-at-destination
2976-minimum-cost-to-convert-string-i
3286-find-a-safe-walk-through-a-grid

Prefix Sum

0209-minimum-size-subarray-sum
0238-product-of-array-except-self
0303-range-sum-query-immutable
0304-range-sum-query-2d-immutable
0525-contiguous-array
0560-subarray-sum-equals-k
0713-subarray-product-less-than-k
0724-find-pivot-index
0974-subarray-sums-divisible-by-k
1004-max-consecutive-ones-iii
1094-car-pooling
1109-corporate-flight-bookings
1208-get-equal-substrings-within-budget
1248-count-number-of-nice-subarrays
1310-xor-queries-of-a-subarray
1423-maximum-points-you-can-obtain-from-cards
1525-number-of-good-ways-to-split-a-string
1732-find-the-highest-altitude
1769-minimum-number-of-operations-to-move-all-balls-to-each-box
1854-maximum-population-year
1856-maximum-subarray-min-product
1893-check-if-all-the-integers-in-a-range-are-covered
1943-describe-the-painting
1991-find-the-middle-index-in-array
2055-plates-between-candles
2100-find-good-days-to-rob-the-bank
2256-minimum-average-difference
2406-divide-intervals-into-minimum-number-of-groups
2574-left-and-right-sum-differences
2848-points-that-intersect-with-cars

Queue

0387-first-unique-character-in-a-string
0918-maximum-sum-circular-subarray
1438-longest-continuous-subarray-with-absolute-diff-less-than-or-equal-to-limit
2762-continuous-subarrays

Recursion

0002-add-two-numbers
0021-merge-two-sorted-lists
0024-swap-nodes-in-pairs
0143-reorder-list
0203-remove-linked-list-elements
0206-reverse-linked-list
0234-palindrome-linked-list
0241-different-ways-to-add-parentheses
0509-fibonacci-number
2487-remove-nodes-from-linked-list

Monotonic Queue

0918-maximum-sum-circular-subarray
1438-longest-continuous-subarray-with-absolute-diff-less-than-or-equal-to-limit
2762-continuous-subarrays

Simulation

0054-spiral-matrix
0059-spiral-matrix-ii
0289-game-of-life
0566-reshape-the-matrix
0682-baseball-game
0735-asteroid-collision
0844-backspace-string-compare
0946-validate-stack-sequences
1006-clumsy-factorial
1094-car-pooling
1441-build-an-array-with-stack-operations
1646-get-maximum-in-generated-array
2011-final-value-of-variable-after-performing-operations
2161-partition-array-according-to-given-pivot
2181-merge-nodes-in-between-zeros
2289-steps-to-make-array-non-decreasing
2390-removing-stars-from-a-string
2558-take-gifts-from-the-richest-pile

Binary Indexed Tree

0673-number-of-longest-increasing-subsequence
1395-count-number-of-teams

Segment Tree

0673-number-of-longest-increasing-subsequence
0729-my-calendar-i
1395-count-number-of-teams
2080-range-frequency-queries

Floyd's Cycle Finding Algorithm

0142-linked-list-cycle-ii

Manacher

0005-longest-palindromic-substring

Ordered Set

0729-my-calendar-i
1348-tweet-counts-per-frequency
1438-longest-continuous-subarray-with-absolute-diff-less-than-or-equal-to-limit
2034-stock-price-fluctuation
2349-design-a-number-container-system
2353-design-a-food-rating-system
2762-continuous-subarrays

Counting Sort

0274-h-index
0561-array-partition
0912-sort-an-array
1122-relative-sort-array
1833-maximum-ice-cream-bars

Quicksort

1122-relative-sort-array

Bubble Sort

1122-relative-sort-array

Longest Increasing Subsequence

0300-longest-increasing-subsequence
0334-increasing-triplet-subsequence
0646-maximum-length-of-pair-chain
0673-number-of-longest-increasing-subsequence

Geometry

0973-k-closest-points-to-origin

K-D Tree

0973-k-closest-points-to-origin

Newton's Method

0069-sqrtx

Interactive

0278-first-bad-version
0374-guess-number-higher-or-lower

Bracket Sequences

0241-different-ways-to-add-parentheses
0678-valid-parenthesis-string
0856-score-of-parentheses
0921-minimum-add-to-make-parentheses-valid
1021-remove-outermost-parentheses
1541-minimum-insertions-to-balance-a-parentheses-string
1614-maximum-nesting-depth-of-the-parentheses
1963-minimum-number-of-swaps-to-make-the-string-balanced

Tree

0094-binary-tree-inorder-traversal
0098-validate-binary-search-tree
0099-recover-binary-search-tree
0100-same-tree
0101-symmetric-tree
0102-binary-tree-level-order-traversal
0104-maximum-depth-of-binary-tree
0105-construct-binary-tree-from-preorder-and-inorder-traversal
0106-construct-binary-tree-from-inorder-and-postorder-traversal
0107-binary-tree-level-order-traversal-ii
0108-convert-sorted-array-to-binary-search-tree
0109-convert-sorted-list-to-binary-search-tree
0110-balanced-binary-tree
0111-minimum-depth-of-binary-tree
0112-path-sum
0113-path-sum-ii
0129-sum-root-to-leaf-numbers
0144-binary-tree-preorder-traversal
0145-binary-tree-postorder-traversal
0173-binary-search-tree-iterator
0199-binary-tree-right-side-view
0226-invert-binary-tree
0230-kth-smallest-element-in-a-bst
0235-lowest-common-ancestor-of-a-binary-search-tree
0236-lowest-common-ancestor-of-a-binary-tree
0257-binary-tree-paths
0331-verify-preorder-serialization-of-a-binary-tree
0337-house-robber-iii
0404-sum-of-left-leaves
0429-n-ary-tree-level-order-traversal
0449-serialize-and-deserialize-bst
0450-delete-node-in-a-bst
0501-find-mode-in-binary-search-tree
0513-find-bottom-left-tree-value
0515-find-largest-value-in-each-tree-row
0530-minimum-absolute-difference-in-bst
0538-convert-bst-to-greater-tree
0543-diameter-of-binary-tree
0559-maximum-depth-of-n-ary-tree
0563-binary-tree-tilt
0572-subtree-of-another-tree
0589-n-ary-tree-preorder-traversal
0590-n-ary-tree-postorder-traversal
0606-construct-string-from-binary-tree
0617-merge-two-binary-trees
0637-average-of-levels-in-binary-tree
0654-maximum-binary-tree
0662-maximum-width-of-binary-tree
0687-longest-univalue-path
0690-employee-importance
0700-search-in-a-binary-search-tree
0701-insert-into-a-binary-search-tree
0703-kth-largest-element-in-a-stream
0783-minimum-distance-between-bst-nodes
0865-smallest-subtree-with-all-the-deepest-nodes
0889-construct-binary-tree-from-preorder-and-postorder-traversal
0897-increasing-order-search-tree
0938-range-sum-of-bst
0979-distribute-coins-in-binary-tree
0993-cousins-in-binary-tree
1008-construct-binary-search-tree-from-preorder-traversal
1022-sum-of-root-to-leaf-binary-numbers
1123-lowest-common-ancestor-of-deepest-leaves
1161-maximum-level-sum-of-a-binary-tree
1315-sum-of-nodes-with-even-valued-grandparent
1372-longest-zigzag-path-in-a-binary-tree
1382-balance-a-binary-search-tree
1448-count-good-nodes-in-binary-tree
1609-even-odd-tree
2096-step-by-step-directions-from-a-binary-tree-node-to-another
2196-create-binary-tree-from-descriptions
2415-reverse-odd-levels-of-binary-tree

Binary Search Tree

0098-validate-binary-search-tree
0099-recover-binary-search-tree
0108-convert-sorted-array-to-binary-search-tree
0109-convert-sorted-list-to-binary-search-tree
0173-binary-search-tree-iterator
0230-kth-smallest-element-in-a-bst
0235-lowest-common-ancestor-of-a-binary-search-tree
0449-serialize-and-deserialize-bst
0450-delete-node-in-a-bst
0501-find-mode-in-binary-search-tree
0530-minimum-absolute-difference-in-bst
0538-convert-bst-to-greater-tree
0700-search-in-a-binary-search-tree
0701-insert-into-a-binary-search-tree
0703-kth-largest-element-in-a-stream
0783-minimum-distance-between-bst-nodes
0897-increasing-order-search-tree
0938-range-sum-of-bst
1008-construct-binary-search-tree-from-preorder-traversal
1382-balance-a-binary-search-tree

Binary Tree

0094-binary-tree-inorder-traversal
0098-validate-binary-search-tree
0099-recover-binary-search-tree
0100-same-tree
0101-symmetric-tree
0102-binary-tree-level-order-traversal
0104-maximum-depth-of-binary-tree
0105-construct-binary-tree-from-preorder-and-inorder-traversal
0106-construct-binary-tree-from-inorder-and-postorder-traversal
0107-binary-tree-level-order-traversal-ii
0108-convert-sorted-array-to-binary-search-tree
0109-convert-sorted-list-to-binary-search-tree
0110-balanced-binary-tree
0111-minimum-depth-of-binary-tree
0112-path-sum
0113-path-sum-ii
0129-sum-root-to-leaf-numbers
0144-binary-tree-preorder-traversal
0145-binary-tree-postorder-traversal
0173-binary-search-tree-iterator
0199-binary-tree-right-side-view
0226-invert-binary-tree
0230-kth-smallest-element-in-a-bst
0235-lowest-common-ancestor-of-a-binary-search-tree
0236-lowest-common-ancestor-of-a-binary-tree
0257-binary-tree-paths
0331-verify-preorder-serialization-of-a-binary-tree
0337-house-robber-iii
0404-sum-of-left-leaves
0449-serialize-and-deserialize-bst
0450-delete-node-in-a-bst
0501-find-mode-in-binary-search-tree
0513-find-bottom-left-tree-value
0515-find-largest-value-in-each-tree-row
0530-minimum-absolute-difference-in-bst
0538-convert-bst-to-greater-tree
0543-diameter-of-binary-tree
0563-binary-tree-tilt
0572-subtree-of-another-tree
0606-construct-string-from-binary-tree
0617-merge-two-binary-trees
0637-average-of-levels-in-binary-tree
0654-maximum-binary-tree
0662-maximum-width-of-binary-tree
0687-longest-univalue-path
0700-search-in-a-binary-search-tree
0701-insert-into-a-binary-search-tree
0703-kth-largest-element-in-a-stream
0783-minimum-distance-between-bst-nodes
0865-smallest-subtree-with-all-the-deepest-nodes
0889-construct-binary-tree-from-preorder-and-postorder-traversal
0897-increasing-order-search-tree
0938-range-sum-of-bst
0979-distribute-coins-in-binary-tree
0993-cousins-in-binary-tree
1008-construct-binary-search-tree-from-preorder-traversal
1022-sum-of-root-to-leaf-binary-numbers
1123-lowest-common-ancestor-of-deepest-leaves
1161-maximum-level-sum-of-a-binary-tree
1315-sum-of-nodes-with-even-valued-grandparent
1372-longest-zigzag-path-in-a-binary-tree
1382-balance-a-binary-search-tree
1448-count-good-nodes-in-binary-tree
1609-even-odd-tree
2096-step-by-step-directions-from-a-binary-tree-node-to-another
2196-create-binary-tree-from-descriptions
2415-reverse-odd-levels-of-binary-tree

Trie

0139-word-break
0692-top-k-frequent-words

String Matching

0572-subtree-of-another-tree

Hash Function

0572-subtree-of-another-tree

Iterator

0173-binary-search-tree-iterator

Cartesian Tree

0654-maximum-binary-tree
1856-maximum-subarray-min-product

Backtracking

0017-letter-combinations-of-a-phone-number
0039-combination-sum
0040-combination-sum-ii
0046-permutations
0047-permutations-ii
0077-combinations
0078-subsets
0079-word-search
0090-subsets-ii
0093-restore-ip-addresses
0113-path-sum-ii
0216-combination-sum-iii
0257-binary-tree-paths
0491-non-decreasing-subsequences
0494-target-sum
0526-beautiful-arrangement
0784-letter-case-permutation
1079-letter-tile-possibilities
1239-maximum-length-of-a-concatenated-string-with-unique-characters
1863-sum-of-all-subset-xor-totals
2597-the-number-of-beautiful-subsets

DP on Trees

0337-house-robber-iii
0543-diameter-of-binary-tree
0563-binary-tree-tilt
0687-longest-univalue-path
0865-smallest-subtree-with-all-the-deepest-nodes
0979-distribute-coins-in-binary-tree
1123-lowest-common-ancestor-of-deepest-leaves
1372-longest-zigzag-path-in-a-binary-tree

Binary Lifting

0235-lowest-common-ancestor-of-a-binary-search-tree
0236-lowest-common-ancestor-of-a-binary-tree
0865-smallest-subtree-with-all-the-deepest-nodes
1123-lowest-common-ancestor-of-deepest-leaves
2096-step-by-step-directions-from-a-binary-tree-node-to-another

Lowest Common Ancestor

0235-lowest-common-ancestor-of-a-binary-search-tree
0236-lowest-common-ancestor-of-a-binary-tree
0865-smallest-subtree-with-all-the-deepest-nodes
1123-lowest-common-ancestor-of-deepest-leaves
2096-step-by-step-directions-from-a-binary-tree-node-to-another

Directed Acyclic Graph

1557-minimum-number-of-vertices-to-reach-all-nodes

Bidirectional Search

0433-minimum-genetic-mutation
0752-open-the-lock

Kosaraju's Algorithm

0802-find-eventual-safe-states

Tarjan's SCC Algorithm

0802-find-eventual-safe-states

Bipartite Graph

0785-is-graph-bipartite
0886-possible-bipartition
0947-most-stones-removed-with-same-row-or-column

Combinatorics

1863-sum-of-all-subset-xor-totals
2597-the-number-of-beautiful-subsets

Enumeration

1863-sum-of-all-subset-xor-totals

Bitmask

0526-beautiful-arrangement

Knapsack Problem

0279-perfect-squares
0322-coin-change
0416-partition-equal-subset-sum
0494-target-sum
0518-coin-change-ii

Complete Knapsack

0279-perfect-squares
0322-coin-change
0518-coin-change-ii

Brute-Force Search

0139-word-break

0-1 Knapsack

0416-partition-equal-subset-sum
0494-target-sum

Graph Coloring

0785-is-graph-bipartite
0886-possible-bipartition

Dijkstra's Algorithm

0743-network-delay-time
1334-find-the-city-with-the-smallest-number-of-neighbors-at-a-threshold-distance
1514-path-with-maximum-probability
1631-path-with-minimum-effort
1976-number-of-ways-to-arrive-at-destination

Bellman–Ford Algorithm

1334-find-the-city-with-the-smallest-number-of-neighbors-at-a-threshold-distance

Floyd–Warshall Algorithm

1334-find-the-city-with-the-smallest-number-of-neighbors-at-a-threshold-distance

Minimum Spanning Tree

1584-min-cost-to-connect-all-points

Prim's Algorithm

1584-min-cost-to-connect-all-points

Kruskal's Algorithm

1584-min-cost-to-connect-all-points

Borůvka's Algorithm

1584-min-cost-to-connect-all-points

Sweep Line

0986-interval-list-intersections

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages