[go: up one dir, main page]

0% found this document useful (0 votes)
127 views10 pages

100 Most Important DSA Question List

The document contains a comprehensive list of algorithm problems categorized by data structures such as arrays, matrices, strings, trees, and graphs, along with links to their respective LeetCode and LintCode pages. Each category includes various problem types like dynamic programming, backtracking, and graph traversal techniques. It serves as a resource for practicing and mastering different algorithmic concepts and problem-solving skills.

Uploaded by

amit dutta
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
127 views10 pages

100 Most Important DSA Question List

The document contains a comprehensive list of algorithm problems categorized by data structures such as arrays, matrices, strings, trees, and graphs, along with links to their respective LeetCode and LintCode pages. Each category includes various problem types like dynamic programming, backtracking, and graph traversal techniques. It serves as a resource for practicing and mastering different algorithmic concepts and problem-solving skills.

Uploaded by

amit dutta
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 10

Array (Hashmap, Hashset, etc)

https://leetcode.com/problems/find-all-duplicates-in-an-array/

https://leetcode.com/problems/find-all-numbers-disappeared-in-an-array/

https://leetcode.com/problems/best-time-to-buy-and-sell-stock/
description/

https://leetcode.com/problems/best-time-to-buy-and-sell-stock-ii/
description/

https://leetcode.com/problems/maximum-subarray/

https://leetcode.com/problems/maximum-product-subarray/

https://leetcode.com/problems/subarray-sum-equals-k/

https://leetcode.com/problems/contiguous-array/

https://www.lintcode.com/problem/maximum-size-subarray-sum-equals-
k/description

https://leetcode.com/problems/next-permutation/

https://www.geeksforgeeks.org/counting-inversions-using-set-in-c-stl/

https://leetcode.com/problems/ugly-number/

https://leetcode.com/problems/ugly-number-ii/

https://leetcode.com/problems/trapping-rain-water/

https://leetcode.com/problems/largest-rectangle-in-histogram/

https://leetcode.com/problems/container-with-most-water/
Array (Hashmap, Hashset, etc)

https://www.lintcode.com/problem/wiggle-sort/description/

Matrix

https://leetcode.com/problems/count-negative-numbers-in-a-sorted-
matrix

https://leetcode.com/problems/search-a-2d-matrix

https://leetcode.com/problems/search-a-2d-matrix-ii

https://leetcode.com/problems/kth-smallest-element-in-a-sorted-matrix

https://leetcode.com/problems/maximal-square/

https://leetcode.com/problems/count-square-submatrices-with-all-ones/

https://leetcode.com/problems/count-submatrices-with-all-ones/

https://leetcode.com/problems/minimum-path-sum/

https://leetcode.com/problems/minimum-falling-path-sum/

Prefix Sum

https://leetcode.com/problems/continuous-subarray-sum/

https://leetcode.com/problems/subarray-sums-divisible-by-k/

Sliding Window

https://leetcode.com/problems/find-all-anagrams-in-a-string/

https://leetcode.com/problems/longest-repeating-character-replacement/
Array (Hashmap, Hashset, etc)

https://leetcode.com/problems/longest-substring-without-repeating-
characters/

https://www.lintcode.com/problem/longest-substring-with-at-most-k-
distinct-characters/description

https://www.lintcode.com/problem/longest-substring-with-at-most-two-
distinct-characters/description

https://leetcode.com/problems/subarrays-with-k-different-integers/

https://leetcode.com/problems/max-consecutive-ones-iii/

https://leetcode.com/problems/fruit-into-baskets/

https://leetcode.com/problems/sliding-window-maximum/

https://leetcode.com/problems/minimum-window-substring/

Intervals

https://leetcode.com/problems/merge-intervals/

https://leetcode.com/problems/remove-covered-intervals/

https://www.lintcode.com/problem/meeting-rooms/description

https://www.lintcode.com/problem/meeting-rooms-ii/description

https://leetcode.com/problems/non-overlapping-intervals/

https://leetcode.com/problems/minimum-number-of-arrows-to-burst-
balloons/

Priority Queue
Array (Hashmap, Hashset, etc)

https://leetcode.com/problems/top-k-frequent-words/submissions/

Linked List

https://leetcode.com/problems/linked-list-cycle/

https://leetcode.com/problems/linked-list-cycle-ii/

https://leetcode.com/problems/reverse-linked-list/

https://leetcode.com/problems/reverse-linked-list-ii/

https://leetcode.com/problems/reverse-nodes-in-k-group/

https://leetcode.com/problems/palindrome-linked-list/

https://leetcode.com/problems/add-two-numbers/

https://leetcode.com/problems/add-two-numbers-ii/

https://leetcode.com/problems/remove-duplicates-from-sorted-list/

https://leetcode.com/problems/remove-duplicates-from-sorted-list-ii/

Binary Search

TEMPLATE: Binary Search Template

https://leetcode.com/problems/find-minimum-in-rotated-sorted-array/

https://leetcode.com/problems/find-minimum-in-rotated-sorted-array-ii/

https://leetcode.com/problems/search-in-rotated-sorted-array/
Array (Hashmap, Hashset, etc)

https://leetcode.com/problems/search-in-rotated-sorted-array-ii/

https://leetcode.com/problems/find-first-and-last-position-of-element-in-
sorted-array/

https://leetcode.com/problems/find-peak-element/

https://leetcode.com/problems/find-a-peak-element-ii/

DP

https://leetcode.com/problems/word-break/

https://leetcode.com/problems/longest-common-subsequence/

https://leetcode.com/problems/longest-increasing-subsequence/

LIS Similar

https://www.pepcoding.com/resources/data-structures-and-algorithms-
in-java-levelup/dynamic-programming/lbs-official/ojquestion

https://leetcode.com/problems/uncrossed-lines/

https://leetcode.com/problems/perfect-squares/

https://leetcode.com/problems/russian-doll-envelopes/

https://leetcode.com/problems/house-robber/

https://leetcode.com/problems/house-robber-ii/

https://leetcode.com/problems/house-robber-iii/
Array (Hashmap, Hashset, etc)

https://leetcode.com/problems/decode-ways/

Strings

Type - Palindromes

https://leetcode.com/problems/longest-palindromic-substring/

https://leetcode.com/problems/palindromic-substrings/

Type - Anagrams

https://leetcode.com/problems/valid-anagram/

https://leetcode.com/problems/group-anagrams/

Backtracking

https://leetcode.com/problems/subsets

https://leetcode.com/problems/subsets-ii

https://leetcode.com/problems/permutations

https://leetcode.com/problems/permutations-ii

https://leetcode.com/problems/combination-sum

https://leetcode.com/problems/combination-sum-ii

https://leetcode.com/problems/generate-parentheses

https://leetcode.com/problems/letter-combinations-of-a-phone-number
Array (Hashmap, Hashset, etc)

https://leetcode.com/problems/word-search/

https://leetcode.com/problems/word-break/

Stack

https://leetcode.com/problems/exclusive-time-of-functions/

Trees

https://leetcode.com/problems/path-sum

https://leetcode.com/problems/path-sum-ii

https://leetcode.com/problems/path-sum-iii

https://leetcode.com/problems/lowest-common-ancestor-of-a-binary-
search-tree

https://leetcode.com/problems/lowest-common-ancestor-of-a-binary-tree/

https://leetcode.com/problems/maximum-depth-of-n-ary-tree/

https://leetcode.com/problems/diameter-of-binary-tree

https://leetcode.com/problems/diameter-of-n-ary-tree/

https://leetcode.com/problems/same-tree/

https://leetcode.com/problems/subtree-of-another-tree/

https://leetcode.com/problems/construct-binary-search-tree-from-
preorder-traversal/
Array (Hashmap, Hashset, etc)

https://leetcode.com/problems/construct-binary-tree-from-preorder-and-
inorder-traversal/

https://leetcode.com/problems/validate-binary-search-tree/

https://www.geeksforgeeks.org/print-nodes-in-the-top-view-of-binary-
tree-set-3/

https://www.geeksforgeeks.org/bottom-view-binary-tree/

https://leetcode.com/problems/binary-tree-zigzag-level-order-traversal/

https://www.lintcode.com/problem/binary-tree-vertical-order-traversal/
description

https://www.geeksforgeeks.org/boundary-traversal-of-binary-tree/

https://www.geeksforgeeks.org/diagonal-traversal-of-binary-tree/

https://www.lintcode.com/en/old/problem/closest-leaf-in-a-binary-tree/

Graphs (DFS)

https://leetcode.com/problems/island-perimeter/

https://leetcode.com/problems/max-area-of-island/

https://leetcode.com/problems/pacific-atlantic-water-flow/

https://leetcode.com/problems/all-paths-from-source-to-target/

https://leetcode.com/problems/reconstruct-itinerary/

https://lintcode.com/en/old/problem/graph-valid-tree/
Array (Hashmap, Hashset, etc)

Border DFS

https://leetcode.com/problems/number-of-closed-islands/

https://leetcode.com/problems/number-of-enclaves/

https://leetcode.com/problems/surrounded-regions/

Graphs (BFS)

https://leetcode.com/problems/shortest-path-in-binary-matrix/

https://leetcode.com/problems/word-ladder/

https://leetcode.com/problems/word-ladder-ii/

https://leetcode.com/problems/minimum-genetic-mutation/

https://leetcode.com/problems/open-the-lock/submissions/

https://leetcode.com/problems/shortest-bridge/ (Can be solved with dfs


and bfs combo)

https://leetcode.com/problems/minimum-cost-to-make-at-least-one-valid-
path-in-a-grid/

Multi Source BFS

https://leetcode.com/problems/rotting-oranges/

https://www.lintcode.com/problem/663/

https://leetcode.com/problems/01-matrix/

Union Find
Array (Hashmap, Hashset, etc)

https://leetcode.com/problems/couples-holding-hands/

https://leetcode.com/problems/redundant-connection/

https://leetcode.com/problems/redundant-connection-ii/

Bipartite Graphs

https://leetcode.com/problems/is-graph-bipartite/

https://leetcode.com/problems/possible-bipartition/

Topological Sorting

https://leetcode.com/problems/course-schedule/

https://leetcode.com/problems/course-schedule-ii/

https://www.lintcode.com/problem/alien-dictionary/description (Not
topological sort but question context is same)

https://www.lintcode.com/problem/alien-dictionary/description

Djikstra

https://leetcode.com/problems/network-delay-time/

Articulation Points

https://leetcode.com/problems/critical-connections-in-a-network/

You might also like