Microsoft coding interview
questions, leaked.
192 problems reported across recent Microsoft interviews. Top patterns: array, string, hash table. The list below is what most candidates actually saw, plus the honest play if you can't grind all of it.
Microsoft interviews 192 distinct problems across their assessment bank, and 97 of them center on arrays. You're looking at 55 easy problems to warm up on, 109 mediums that form the real gauntlet, and 28 hards for the high bar. Two Sum, Merge Sorted Array, and Valid Parentheses are the canonical starters, but the medium tier (Longest Substring Without Repeating Characters, 3Sum, Maximum Subarray) is where most candidates lose time. Hash tables and two-pointers show up constantly. If you freeze mid-assessment on a pattern you haven't drilled, StealthCoder runs invisibly and surfaces a working solution in seconds, so you keep moving.
Top problems at Microsoft
| # | Problem | Diff | Frequency | Pass % | Patterns |
|---|---|---|---|---|---|
| 01 | Two Sum | EASY | 100.0 | 56% | Array · Hash Table |
| 02 | Merge Sorted Array | EASY | 83.7 | 53% | Array · Two Pointers · Sorting |
| 03 | Longest Substring Without Repeating Characters | MEDIUM | 79.4 | 37% | Hash Table · String · Sliding Window |
| 04 | Add Two Numbers | MEDIUM | 78.3 | 46% | Linked List · Math · Recursion |
| 05 | Longest Palindromic Substring | MEDIUM | 75.8 | 36% | Two Pointers · String · Dynamic Programming |
| 06 | Trapping Rain Water | HARD | 75.7 | 65% | Array · Two Pointers · Dynamic Programming |
| 07 | Merge Intervals | MEDIUM | 73.8 | 49% | Array · Sorting |
| 08 | Median of Two Sorted Arrays | HARD | 72.9 | 44% | Array · Binary Search · Divide and Conquer |
| 09 | Valid Parentheses | EASY | 72.9 | 42% | String · Stack |
| 10 | 3Sum | MEDIUM | 72.9 | 37% | Array · Two Pointers · Sorting |
| 11 | Maximum Subarray | MEDIUM | 72.9 | 52% | Array · Divide and Conquer · Dynamic Programming |
| 12 | Group Anagrams | MEDIUM | 69.8 | 71% | Array · Hash Table · String |
| 13 | Search in Rotated Sorted Array | MEDIUM | 68.5 | 43% | Array · Binary Search |
| 14 | Reverse Nodes in k-Group | HARD | 68.5 | 63% | Linked List · Recursion |
| 15 | Merge Two Sorted Lists | EASY | 68.5 | 67% | Linked List · Recursion |
| 16 | Roman to Integer | EASY | 68.3 | 65% | Hash Table · Math · String |
| 17 | Spiral Matrix | MEDIUM | 68.3 | 54% | Array · Matrix · Simulation |
| 18 | Climbing Stairs | EASY | 68.0 | 54% | Math · Dynamic Programming · Memoization |
| 19 | Container With Most Water | MEDIUM | 67.7 | 58% | Array · Two Pointers · Greedy |
| 20 | Rotate Image | MEDIUM | 67.7 | 78% | Array · Math · Matrix |
| 21 | Palindrome Number | EASY | 67.5 | 59% | Math |
| 22 | Merge k Sorted Lists | HARD | 67.5 | 57% | Linked List · Divide and Conquer · Heap (Priority Queue) |
| 23 | Sort Colors | MEDIUM | 65.8 | 68% | Array · Two Pointers · Sorting |
| 24 | Longest Common Prefix | EASY | 65.8 | 45% | String · Trie |
| 25 | Remove Duplicates from Sorted Array | EASY | 64.5 | 60% | Array · Two Pointers |
| 26 | Set Matrix Zeroes | MEDIUM | 62.9 | 61% | Array · Hash Table · Matrix |
| 27 | Reverse Integer | MEDIUM | 62.5 | 30% | Math |
| 28 | Letter Combinations of a Phone Number | MEDIUM | 62.5 | 64% | Hash Table · String · Backtracking |
| 29 | Word Search | MEDIUM | 60.6 | 45% | Array · String · Backtracking |
| 30 | Generate Parentheses | MEDIUM | 60.2 | 77% | String · Dynamic Programming · Backtracking |
| 31 | Minimum Edge Reversals So Every Node Is Reachable | HARD | 0.0 | 55% | Dynamic Programming · Depth-First Search · Breadth-First Search |
| 32 | Find Peak Element | MEDIUM | 0.0 | 47% | Array · Binary Search |
| 33 | Best Time to Buy and Sell Stock | EASY | 0.0 | 55% | Array · Dynamic Programming |
| 34 | Move Zeroes | EASY | 0.0 | 63% | Array · Two Pointers |
| 35 | K-th Smallest in Lexicographical Order | HARD | 0.0 | 46% | Trie |
| 36 | Max Consecutive Ones | EASY | 0.0 | 62% | Array |
| 37 | Minimum Size Subarray Sum | MEDIUM | 0.0 | 49% | Array · Binary Search · Sliding Window |
| 38 | Jump Game | MEDIUM | 59.4 | 39% | Array · Dynamic Programming · Greedy |
| 39 | Next Permutation | MEDIUM | 59.0 | 43% | Array · Two Pointers |
| 40 | Remove Element | EASY | 58.1 | 60% | Array · Two Pointers |
| 41 | Minimum Path Sum | MEDIUM | 58.1 | 66% | Array · Dynamic Programming · Matrix |
| 42 | Binary Tree Zigzag Level Order Traversal | MEDIUM | 57.6 | 62% | Tree · Breadth-First Search · Binary Tree |
| 43 | String to Integer (atoi) | MEDIUM | 55.6 | 19% | String |
| 44 | Validate Binary Search Tree | MEDIUM | 55.6 | 34% | Tree · Depth-First Search · Binary Search Tree |
| 45 | Largest Rectangle in Histogram | HARD | 54.6 | 47% | Array · Stack · Monotonic Stack |
| 46 | Find First and Last Position of Element in Sorted Array | MEDIUM | 54.6 | 47% | Array · Binary Search |
| 47 | Combination Sum | MEDIUM | 54.6 | 75% | Array · Backtracking |
| 48 | Find the Index of the First Occurrence in a String | EASY | 54.6 | 45% | Two Pointers · String · String Matching |
| 49 | First Missing Positive | HARD | 54.6 | 41% | Array · Hash Table |
| 50 | Jump Game II | MEDIUM | 54.0 | 42% | Array · Dynamic Programming · Greedy |
Frequencies derived from public community-tagged interview reports. Click a row to view on LeetCode.
You have a week, maybe less. You can't out-grind the list above. StealthCoder runs invisibly during the actual Microsoft OA. The proctor cannot see it. Screen share cannot detect it. Made by a working Amazon engineer who got tired of watching qualified friends bomb OAs they'd solve cold in an IDE.
Get StealthCoder- array97 · 51%
- string43 · 22%
- hash table36 · 19%
- two pointers31 · 16%
- dynamic programming30 · 16%
- math23 · 12%
- sorting21 · 11%
- binary search19 · 10%
- linked list18 · 9%
- tree18 · 9%
Arrays dominate at 97 problems, meaning 50 percent of the bank is array-focused. Strings come second at 43, hash tables at 36. Two-pointers and dynamic programming tie at 30 and 31 respectively, which signals Microsoft loves optimization and multi-pass solutions. The medium difficulty spread (109 out of 192) means you'll spend most of your interview time there, not on easy wins. Trapping Rain Water and Median of Two Sorted Arrays are the hard outliers that require binary search or stack intuition. The real prep bottleneck is drilling two-pointer and hash-table patterns until they're automatic, because combining those two on a string or array problem under time pressure is where most candidates stall. StealthCoder is your hedge for the live moment when a sliding-window or monotonic-stack variant throws you off.
Companies with similar patterns
If you prepped for Microsoft, these companies recycle ~60% of the same topics.
You've seen the list.
Now make sure you pass Microsoft.
Memorizing every problem above in a week is a fantasy. StealthCoder is the hedge: an AI overlay that's invisible during screen share. It reads the problem on screen and surfaces a working solution in under 2 seconds. Made by a working Amazon engineer who got tired of watching qualified friends bomb OAs they'd solve cold in an IDE. Works on HackerRank, CodeSignal, CoderPad, and Karat.
Microsoft interview FAQ
How many array problems should I solve before the Microsoft assessment?+
Microsoft has 97 array problems in their bank, and 50 of them sit in the medium range. Aim to solve at least 20-25 medium array problems, focusing on two-pointers and sliding window first (those appear across multiple difficulty levels). Two Sum and Merge Sorted Array are your easy anchors, then graduate to 3Sum, Maximum Subarray, and Trapping Rain Water.
Is hash table fluency enough for Microsoft, or do I need dynamic programming too?+
You need both. Hash tables appear in 36 problems, dynamic programming in 30. Hash tables show up earlier and more frequently in screening rounds, so master those first (Group Anagrams, Longest Substring Without Repeating Characters). But 16 percent of the bank is dynamic programming, and some mediums blend them, so don't skip DP entirely.
What should I study first for a Microsoft assessment?+
Arrays and two-pointers. Half the bank is arrays (97 problems), and two-pointers unlock 31 of them with O(n) solutions instead of brute force. Start with Merge Sorted Array and 3Sum, then move to Longest Palindromic Substring and Trapping Rain Water. You'll build the intuition that carries you through harder mediums.
Do I need to solve all 192 problems to pass Microsoft?+
No. You'll see maybe 2-3 problems in an actual assessment. Focus on the top topics: array (97), string (43), and hash table (36) cover about 80 percent of the bank. Hit 30-40 medium problems across those three categories and you're well-prepped. The 28 hard problems are a stretch goal, not a requirement.
Are linked-list and tree problems common in Microsoft interviews?+
Less common than arrays and strings, but they do appear. Linked list problems (18 total) and tree problems (18 total) cluster in the medium range. Merge Two Sorted Lists and Reverse Nodes in k-Group are representative. If you're short on time, defer heavy tree drilling and focus on arrays, two-pointers, and hash tables first.