Title: Coding Interview Patterns: 14 Most-Asked DSA Patterns | LeakCode
Open Graph Title: Coding Interview Patterns: 14 Most-Asked DSA Patterns | LeakCode
X Title: Coding Interview Patterns: 14 Most-Asked DSA Patterns | LeakCode
Description: The 14 coding patterns that cover 90% of interview questions: two pointer, sliding window, binary search, DP, BFS/DFS, monotonic stack, and more. Templates, complexity, and classic problems.
Open Graph Description: The 14 coding patterns that cover 90% of interview questions: two pointer, sliding window, binary search, DP, BFS/DFS, monotonic stack, and more. Templates, complexity, and classic problems.
X Description: The 14 coding patterns that cover 90% of interview questions: two pointer, sliding window, binary search, DP, BFS/DFS, monotonic stack, and more. Templates, complexity, and classic problems.
Opengraph URL: https://leakcode.dev/patterns
X: @leakcode
Domain: leakcode.dev
{
"@context": "https://schema.org",
"@type": "Organization",
"@id": "https://leakcode.dev/#organization",
"name": "LeakCode",
"url": "https://leakcode.dev",
"logo": {
"@type": "ImageObject",
"url": "https://leakcode.dev/static/logo.svg",
"width": 140,
"height": 31
},
"sameAs": [
"https://twitter.com/leakcode",
"https://discord.com/invite/cSchaxMtMq",
"https://github.com/techreign/awesome-leaked-interview-questions",
"https://github.com/techreign/leakcode-cli",
"https://github.com/techreign/interview-prep-resources",
"https://github.com/techreign/company-name-aliases",
"https://techreign.github.io/awesome-leaked-interview-questions/",
"https://techreign.github.io/leakcode-cli/",
"https://techreign.github.io/interview-prep-resources/",
"https://techreign.github.io/company-name-aliases/",
"https://www.kaggle.com/datasets/manifoldinfo/interview-questions-aggregated-sample",
"https://www.kaggle.com/manifoldinfo",
"https://gist.github.com/techreign/22c6af4d896e51b78c38d59ec0f02813",
"https://gist.github.com/techreign/fb720b69b433f3e7678bb6b349033836",
"https://gist.github.com/techreign/7147bc146488e578d5a3937d35b146fb",
"https://gist.github.com/techreign/23503909ee1ae6860b12bd5c7b0dd4de",
"https://gist.github.com/techreign/0555df055f74b864ba115601932f6071",
"https://gist.github.com/techreign/94669dac2eb3610aabd3e8c26e10e378",
"https://github.com/techreign/faang-interview-data-2026",
"https://github.com/techreign/best-leetcode-resources",
"https://github.com/techreign/awesome-competitive-programming",
"https://github.com/techreign/awesome-leetcode-resources",
"https://github.com/techreign/interviews",
"https://github.com/techreign/coding-interview-university",
"https://github.com/techreign/FAANG-Coding-Interview-Questions",
"https://github.com/techreign/awesome-interview",
"https://github.com/techreign/tech-interview-handbook",
"https://techreign.github.io/best-leetcode-resources/",
"https://techreign.github.io/awesome-leetcode-resources/",
"https://techreign.github.io/interviews/",
"https://techreign.github.io/coding-interview-university/",
"https://techreign.github.io/FAANG-Coding-Interview-Questions/",
"https://techreign.github.io/awesome-interview/",
"https://techreign.github.io/tech-interview-handbook/"
],
"contactPoint": {
"@type": "ContactPoint",
"contactType": "customer support",
"url": "https://leakcode.dev/support",
"email": "manifoldinfo@gmail.com"
},
"description": "LeakCode aggregates 59,970 real interview questions from 2,000+ companies across 7 sources including 1Point3Acres, LeetCode Premium, Blind, Glassdoor, and Reddit. Translated, classified, and searchable.",
"disambiguatingDescription": "LeakCode (leakcode.dev) is an interview question aggregator. It is not affiliated with LeetCode (leetcode.com), which is a separate coding practice platform."
}
{
"@context": "https://schema.org",
"@type": "WebSite",
"@id": "https://leakcode.dev/#website",
"name": "LeakCode",
"url": "https://leakcode.dev",
"publisher": {"@id": "https://leakcode.dev/#organization"},
"potentialAction": {
"@type": "SearchAction",
"target": {
"@type": "EntryPoint",
"urlTemplate": "https://leakcode.dev/search?q={search_term_string}"
},
"query-input": "required name=search_term_string"
}
}
| og:site_name | LeakCode |
| og:type | website |
| og:image | https://leakcode.dev/static/og-image.png |
| og:image:width | 1200 |
| og:image:height | 630 |
| twitter:card | summary_large_image |
| twitter:image | https://leakcode.dev/static/og-image.png |
Links:
| https://leakcode.dev/ | |
| Companies | https://leakcode.dev/browse |
| Guides | https://leakcode.dev/guides |
| Patterns | https://leakcode.dev/patterns |
| System Design | https://leakcode.dev/system-design |
| About | https://leakcode.dev/about |
| FAQ | https://leakcode.dev/faq |
| Pricing | https://leakcode.dev/pricing |
| Sign in | https://leakcode.dev/login |
| Get Access | https://leakcode.dev/signup |
| Companies | https://leakcode.dev/browse |
| Guides | https://leakcode.dev/guides |
| Patterns | https://leakcode.dev/patterns |
| System Design | https://leakcode.dev/system-design |
| About | https://leakcode.dev/about |
| FAQ | https://leakcode.dev/faq |
| Pricing | https://leakcode.dev/pricing |
| Sign in | https://leakcode.dev/login |
| Get Access | https://leakcode.dev/signup |
| LeakCode | https://leakcode.dev/ |
| Two Pointer When you see a sorted array or a linked list problem with pair/triplet semantics, two pointers is almost always the right tool. 7 classic problems | https://leakcode.dev/patterns/two-pointer |
| Sliding Window Substring and subarray problems with a contiguous-range constraint collapse to O(n) via two pointers that only expand. 7 classic problems | https://leakcode.dev/patterns/sliding-window |
| Binary Search Not just for sorted arrays. Binary search the answer space when the predicate is monotonic and the bounds are integer. 7 classic problems | https://leakcode.dev/patterns/binary-search |
| Monotonic Stack Next-greater, next-smaller, and span problems are all the same pattern with the same O(n) stack invariant. 7 classic problems | https://leakcode.dev/patterns/monotonic-stack |
| Fast and Slow Pointer Floyd's tortoise and hare: detect cycles, find middle, and reverse-with-finds in O(1) extra space on linked lists. 7 classic problems | https://leakcode.dev/patterns/fast-and-slow-pointer |
| Merge Intervals Any 'overlapping ranges' problem sorts by start, then sweeps left-to-right with a single accumulator. 7 classic problems | https://leakcode.dev/patterns/merge-intervals |
| Topological Sort Dependency ordering on a DAG: Kahn's BFS or DFS post-order, both O(V+E). 7 classic problems | https://leakcode.dev/patterns/topological-sort |
| Union Find Connected components, redundancy detection, and Kruskal's MST all reduce to find + union with path compression. 7 classic problems | https://leakcode.dev/patterns/union-find |
| Backtracking Permutations, combinations, partitions, and constraint-satisfaction problems share the same recursive shape. 9 classic problems | https://leakcode.dev/patterns/backtracking |
| Dynamic Programming DP is recognition: identify the state, the transition, and the order. The rest is implementation. 9 classic problems | https://leakcode.dev/patterns/dynamic-programming |
| Graph BFS Shortest path in unweighted graphs, level-order traversal, and multi-source spreading all use the same queue loop. 7 classic problems | https://leakcode.dev/patterns/graph-bfs |
| Graph DFS Cycle detection, connected components, and most tree-recursion variants use DFS with three states. 7 classic problems | https://leakcode.dev/patterns/graph-dfs |
| Prefix Sum Range sum queries collapse from O(n) per query to O(1) with one precomputation pass. 7 classic problems | https://leakcode.dev/patterns/prefix-sum |
| Heap / Top K Elements K-th largest, K closest points, and merge-K-streams problems all collapse to a size-K heap. 7 classic problems | https://leakcode.dev/patterns/heap-top-k |
| System design problems | https://leakcode.dev/system-design |
| All DP questions | https://leakcode.dev/topic/dynamic-programming-interview-questions |
| All interview guides | https://leakcode.dev/guides |
| Browse Companies | https://leakcode.dev/browse |
| Search Questions | https://leakcode.dev/search |
| Trending Problems | https://leakcode.dev/questions/trending |
| Pricing | https://leakcode.dev/pricing |
| Sign Up Free | https://leakcode.dev/signup |
| All Guides | https://leakcode.dev/guides |
| Coding Patterns | https://leakcode.dev/patterns |
| System Design Problems | https://leakcode.dev/system-design |
| FAANG Interview Prep | https://leakcode.dev/guides/faang-interview-prep |
| Behavioral Questions | https://leakcode.dev/guides/behavioral-questions |
| Salary Negotiation | https://leakcode.dev/guides/salary-negotiation |
| Interview Glossary | https://leakcode.dev/glossary |
| Blog | https://leakcode.dev/blog |
| LeakCode Stats | https://leakcode.dev/stats |
| How It Works | https://leakcode.dev/how-it-works |
| Data Sources | https://leakcode.dev/sources |
| FAQ | https://leakcode.dev/faq |
| Changelog | https://leakcode.dev/changelog |
| vs LeetCode | https://leakcode.dev/compare/leakcode-vs-leetcode |
| vs 1Point3Acres | https://leakcode.dev/compare/leakcode-vs-1point3acres |
| https://leakcode.dev/company/google | |
| Meta | https://leakcode.dev/company/meta |
| Amazon | https://leakcode.dev/company/amazon |
| Microsoft | https://leakcode.dev/company/microsoft |
| Apple | https://leakcode.dev/company/apple |
| All Companies | https://leakcode.dev/browse |
| Leaked Questions | https://leakcode.dev/leaked |
| Popular Questions | https://leakcode.dev/popular |
| Asked-At Questions | https://leakcode.dev/asked-at |
| Latest Questions | https://leakcode.dev/latest |
| Recent Questions | https://leakcode.dev/recent |
| About LeakCode | https://leakcode.dev/about |
| Press | https://leakcode.dev/press |
| Support | https://leakcode.dev/support |
| Terms of Service | https://leakcode.dev/terms |
| Privacy Policy | https://leakcode.dev/privacy |
| Site Map | https://leakcode.dev/sitemap |
| Discord | https://discord.gg/cSchaxMtMq |
| Open Source | https://github.com/techreign/awesome-leaked-interview-questions |
| manifoldhub.com/store | https://manifoldhub.com/store/?ref=leakcode |
Viewport: width=device-width, initial-scale=1.0