every pattern they ask
DSA Atlas
The coding patterns behind the problems 44 companies ask. Pick a pattern to see its problems, most widely asked first.
- Two Pointers218 problems · 27 hardTwo indexes walk the input, often from both ends, so you skip the nested loop.
- Sliding Window140 problems · 36 hardA range over an array or string that grows and shrinks as you scan.
- Prefix Sum210 problems · 57 hardRunning totals that answer any range sum in one step.
- Binary Search292 problems · 100 hardHalve the search space each step, on sorted data or on the answer itself.
- Sorting455 problems · 103 hardPut things in order first; then the rest is often one pass.
- Depth-First Search302 problems · 72 hardGo deep down one path before backing up, in trees, graphs and grids.
- Breadth-First Search234 problems · 60 hardExplore level by level; it finds shortest paths when every step costs the same.
- Backtracking101 problems · 31 hardBuild an answer one choice at a time and undo the choice when it fails.
- Dynamic Programming519 problems · 241 hardSolve each overlapping subproblem once and reuse the answer.
- Greedy395 problems · 85 hardTake the best choice right now, once you can show it never hurts later.
- Monotonic Stack79 problems · 31 hardA stack kept in order, for "next greater" and span questions.
- Union-Find87 problems · 38 hardTrack which items are connected as you merge groups.
- Topological Sort35 problems · 20 hardOrder tasks so each comes after everything it depends on.
- Bit Manipulation211 problems · 63 hardWork on the binary form of numbers with masks and shifts.
Patterns come from each problem's LeetCode topic tags, so one problem can be under several patterns.
Credits
These lists are the work of two open GitHub projects. Thank you to their authors.
- liquidslr/leetcode-company-wise-problems: the problem lists for each company (titles, difficulty, frequency, topics, LeetCode links).
- nishant-Tiwari24/company-wise-dsa: the focus tip and important topics shown on each company card.
Problem text stays on LeetCode; we link to it. Frequencies are relative within a company.
Last synced