Microsoft interview practice

Microsoft interview questions

397 questions; coding questions sorted by reports.

FastPrep has 345 coding questions tagged Microsoft, plus 39 system design and 13 low-level design questions. Filter them by interview stage and open any one to practice it.

Questions
397 (345 coding, 52 design and project)
By stage
Online Assessment 127 · Phone Screen 37 · Onsite 192
Updated

Question list

All 345 Microsoft coding questions

Sorted by how many times each question was reported. Pick a stage to see only its questions.

Showing 345 of 345 Microsoft questions.

QuestionDifficultyStageReports
Least Recently Used CacheHash TableDesignMediumOA · Phone · Onsite12 reports · last Oct 2026
Maximum Escape Game ScoreArrayHash TableMediumOA7 reports · last Nov 2026
Authentication SystemHash TableDesignMediumOA6 reports · last Nov 2026
Reverse a Singly Linked ListLinked ListRecursionEasyOnsite6 reports · last Jul 2026
Minimum Cost K-Capable ModelsArrayGreedyMediumOA5 reports · last Nov 2026
Minimum Non-Adjacent Selection CapabilityArrayBinary SearchMediumOA5 reports · last Oct 2026
Valid ParenthesesStackStringEasyOnsite4 reports · last Nov 2026
Maximize Pipeline Throughput Under a Scaling BudgetBinary SearchGreedyMediumOA4 reports · last Nov 2026
Maximum Score with Prime JumpsArrayDynamic ProgrammingMediumOA4 reports · last Oct 2026
Maximum Valid Substring FrequencyStringHash TableMediumOA4 reports · last Oct 2026
Maximum Reward PointsArrayGreedyMediumOA4 reports · last Sep 2026
Retain Top K ValuesArraySortingEasyPhone · Onsite4 reports · last Aug 2026
Implement Queue Using StacksStackQueueEasyOnsite4 reports · last Jul 2026
Deterministic K-Means AssignmentsArrayMathHardPhone · Onsite4 reports · last May 2026
Maximum String OperationsStringGreedyMediumOA3 reports · last Nov 2026
Longest Substring Without Repeating CharactersStringSliding WindowMediumOnsite3 reports · last Nov 2026
Maximum Interactive Team SizeArraySortingMediumOA3 reports · last Nov 2026
Capacity to Ship Packages Within DaysArrayBinary SearchMediumOA · Onsite3 reports · last Oct 2026
K Most Recent Unique Request IDsArrayHash TableEasyOA3 reports · last Oct 2026
3SumArraySortingMediumPhone · Onsite3 reports · last Sep 2026
Minimum Fuel Cost Between CitiesGraphShortest PathHardOA3 reports · last Aug 2026
Binary Tree Zigzag Level Order TraversalTreeBreadth-First SearchMediumOnsite3 reports · last Aug 2026
0/1 KnapsackDynamic ProgrammingArrayMediumOA · Onsite3 reports · last Aug 2026
XOR MultiplicationBit ManipulationMathMediumOA3 reports · last Jul 2026
Majority ElementArrayHash TableEasyOnsite3 reports · last Jul 2026
Climbing StairsDynamic ProgrammingMathEasyOnsite3 reports · last Jun 2026
Merge IntervalsIntervalsSortingMediumOnsite3 reports · last May 2026
Build a Precision-Recall CurveArraySortingMediumOnsite3 reports · last Nov 2025
Number of IslandsMatrixGraphMediumOnsite3 reports · last Mar 2025
Most Visited Sprint MarkerArrayPrefix SumMediumOA2 reports · last Nov 2026
Minimum Time to Rot All OrangesArrayMatrixMediumOnsite2 reports · last Nov 2026
Count Digit Replacements with No Equal Adjacent DigitsStringDynamic ProgrammingMediumOA2 reports · last Oct 2026
Group AnagramsStringArrayMediumOnsite2 reports · last Oct 2026
Prepare NotificationStringGreedyEasyOA2 reports · last Oct 2026
Shortest Board Length to Cover HolesSortingBinary SearchMediumOA2 reports · last Oct 2026
Greedy and Beam Sentence DecodingHeapGreedyHardPhone · Onsite2 reports · last Sep 2026
Shopkeeper Final Price SummaryArrayStackMediumOA2 reports · last Sep 2026
Minimum Jump CostArrayDynamic ProgrammingMediumOA2 reports · last Sep 2026
Implement a TrieTrieDesignMediumOnsite2 reports · last Sep 2026
Maximum Decrypted ScoreArraySliding WindowMediumOA2 reports · last Sep 2026
Minimum Team Size From Every StartArraySliding WindowMediumOA2 reports · last Sep 2026
Arithmetic Expression EvaluatorStringStackHardPhone2 reports · last Sep 2026
Infer a Lexicographically Smallest Alien AlphabetStringGraphHardPhone · Onsite2 reports · last Aug 2026
Filter Anagrams of a TargetArrayStringEasyOnsite2 reports · last Aug 2026
Palindrome Linked List with RestorationLinked ListTwo PointersMediumOnsite2 reports · last Aug 2026
Sorted Subsets of a StringStringBacktrackingMediumPhone2 reports · last Aug 2026
Maximum SubarrayArrayDynamic ProgrammingEasyOnsite2 reports · last Aug 2026
Neural Network Subnetwork StrengthTreeDepth-First SearchHardOA2 reports · last Jul 2026
Word Break II: All SentencesStringDynamic ProgrammingHardPhone · Onsite2 reports · last Jun 2026
Search in Rotated Sorted ArrayArrayBinary SearchMediumOnsite2 reports · last Jun 2026
Array With Set AllDesignHash TableMediumOnsite2 reports · last Jun 2026
Min StackStackDesignMediumPhone · Onsite2 reports · last Apr 2026
All Minimum-Difference PairsArraySortingEasyOnsite2 reports · last Mar 2026
Battleships in a BoardArrayMatrixMediumOnsite2 reports · last Feb 2026
Longest Increasing SubsequenceArrayDynamic ProgrammingMediumOnsite2 reports · last Dec 2025
Isomorphic StringsHash TableStringEasyOnsite2 reports · last Nov 2025
Separate-Chaining Hash TableHash TableDesignMediumOnsite2 reports · last Sep 2025
Maximum Weighted Sum with Disjoint Adjacent SwapsArrayDynamic ProgrammingMediumOA2 reports · last Sep 2025
Course Schedule FeasibilityGraphTopological SortMediumOnsite2 reports · last Jul 2025
Maximum Number PossibleStringGreedyEasyOA2 reports · last May 2025
Minimum Swaps Required to Group All Red Balls TogetherArraySliding WindowMediumOA2 reports · last May 2025
Side Largest Square 🟧MathBinary SearchMediumOA2 reports · last Feb 2025
Reorder Routes to Make All Paths Lead to the City ZeroGraphBreadth-First SearchMediumOA2 reports · last Jan 2025
Is Graph Bipartite?GraphBreadth-First SearchMediumOnsite2 reports · last Feb 2022
Compute Population VarianceArrayMathMediumOnsite2 reports · last Mar 2021
Config Store with Priority OverridesHash TableDesignEasyPhone1 report · last Nov 2026
Bad Request AlertsArrayQueueEasyOnsite1 report · last Nov 2026
Minimum Cost to Process Priority TasksRecursionBinary SearchMediumOA1 report · last Nov 2026
Count a User's Actions in an Event LogHash TableStringEasyOnsite1 report · last Nov 2026
Smallest Batch Size Within a Step LimitArrayBinary SearchMediumOnsite1 report · last Nov 2026
Count Subarrays with Equal Even and Odd CountsArrayHash TableMediumOnsite1 report · last Nov 2026
Count Subarrays with a Perfect-Square ProductArrayHash TableMediumOA1 report · last Nov 2026
Coin ChangeArrayDynamic ProgrammingMediumOnsite1 report · last Oct 2026
Daily USD Totals with Effective-Dated Exchange RatesDatabaseMediumOnsite1 report · last Oct 2026
Number Words to Digits in Any LanguageStackStringMediumOnsite1 report · last Oct 2026
Totals from a Tiered Rate TableArrayPrefix SumMediumOnsite1 report · last Oct 2026
Corporation Reporting LinesDesignHash TableMediumPhone1 report · last Oct 2026
Fewest Buses with the Full RouteGraphBreadth-First SearchHardOnsite1 report · last Oct 2026
Pizza Price CalculatorHash TableArrayEasyOnsite1 report · last Oct 2026
Random Forest Classifier from ScratchTreeRecursionHardPhone1 report · last Oct 2026
Find Available Meeting RoomsArrayIntervalsMediumOA1 report · last Oct 2026
Maximum Sum of a K-StarGraphHeapMediumOA1 report · last Oct 2026
Set Matrix ZeroesArrayMatrixMediumOnsite1 report · last Oct 2026
Balance a Chemical EquationStringParsingHardOA1 report · last Oct 2026
Generate Fixed-Size CombinationsBacktrackingCombinatoricsMediumOnsite1 report · last Oct 2026
Match a Descendant Selector in a DOM TreeTreeDepth-First SearchMediumOnsite1 report · last Oct 2026
Minimum Changes for a Beautiful StringStringDynamic ProgrammingMediumOA1 report · last Oct 2026
Earliest Time to Schedule a MeetingArrayStringMediumOA1 report · last Oct 2026
Minimum Server Connection CostsArraySortingMediumOA1 report · last Oct 2026
Copy a Doubly Linked List with a Special PointerLinked ListHash TableMediumOnsite1 report · last Oct 2026
Maximum Alloy Production Within BudgetArrayBinary SearchMediumOA1 report · last Oct 2026
Count Nondecreasing Digit-Sum ArraysDynamic ProgrammingCombinatoricsHardOA1 report · last Oct 2026
Minimum Operations to Reduce an Integer to ZeroGreedyBit ManipulationMediumOA1 report · last Oct 2026
Amount of Time to Infect a TreeGraphBreadth-First SearchMediumOnsite1 report · last Oct 2026
K-Second Message SuppressionArrayHash TableEasyOnsite1 report · last Oct 2026
Max Consecutive Ones IIIArraySliding WindowMediumOnsite1 report · last Oct 2026
Maximum Subarray Sum Across K ConcatenationsArrayDynamic ProgrammingMediumOnsite1 report · last Oct 2026
Reconstruct One Sentence From a DictionaryStringDynamic ProgrammingMediumOnsite1 report · last Oct 2026
Reduce Array Size to At Most HalfArrayGreedyMediumOnsite1 report · last Oct 2026
Foreground Region SizesMatrixBreadth-First SearchMediumOnsite1 report · last Sep 2026
Top K Frequent ElementsHash TableHeapMediumPhone1 report · last Sep 2026
Grid Paths with Override PassesDynamic ProgrammingMatrixMediumOA1 report · last Sep 2026
Weighted LFU CacheHash TableHeapHardOA1 report · last Sep 2026
Copy File Bytes with Partial WritesSimulationArrayEasyOnsite1 report · last Sep 2026
Longest Repeating Character ReplacementStringSliding WindowMediumOnsite1 report · last Sep 2026
First Duplicate ValueArrayHash TableEasyOnsite1 report · last Sep 2026
Keyed Bounded Executor ScheduleHeapQueueHardOnsite1 report · last Sep 2026
Convert Hexadecimal to Dotted IPv4MathStringEasyOnsite1 report · last Sep 2026
Parse a Signed Integer in Any BaseMathStringMediumOnsite1 report · last Sep 2026
Reconstruct Digits from Jumbled English WordsHash TableMathMediumOnsite1 report · last Sep 2026
Stable Unique Column RenamesHash TableStringMediumOnsite1 report · last Sep 2026
Asteroid CollisionArrayStackMediumOA1 report · last Sep 2026
Minimize Adjacent Squared-Difference Cost with One InsertionArrayMathMediumOA1 report · last Sep 2026
Validate and Complete Racer PrecedenceGraphTopological SortMediumOnsite1 report · last Sep 2026
Word SearchMatrixDepth-First SearchMediumOnsite1 report · last Sep 2026
Count Binary SubstringsStringTwo PointersEasyOA1 report · last Sep 2026
Count Numbers with the Same Set-Bit CountBit ManipulationCombinatoricsMediumOA1 report · last Sep 2026
Equalize Arrays with Prefix and Suffix IncrementsArrayGreedyMediumOA1 report · last Sep 2026
Longest Substring with At Most K Distinct CharactersStringSliding WindowMediumOA1 report · last Sep 2026
Sort Words by LengthStringSortingEasyOnsite1 report · last Sep 2026
Maximum Non-Overlapping IntervalsIntervalsGreedyMediumOnsite1 report · last Sep 2026
Employee Hierarchy Cycle and Depth AnalysisGraphDepth-First SearchMediumPhone1 report · last Sep 2026
Most Visited String SectorsArraySimulationEasyPhone1 report · last Sep 2026
Minimum Length Good SubarrayArrayHash TableMediumOA1 report · last Aug 2026
Roll the StringStringArrayMediumOA1 report · last Aug 2026
Suffix Maximum Frequency QueriesArrayDynamic ProgrammingEasyPhone1 report · last Aug 2026
Maximum Stock Profit with At Most Two TransactionsArrayDynamic ProgrammingMediumOnsite1 report · last Aug 2026
Subtract Forward-Order Linked-List NumbersLinked ListStackMediumOnsite1 report · last Aug 2026
Generate a Spiral MatrixMatrixSimulationMediumOnsite1 report · last Aug 2026
Spiral Matrix TraversalMatrixSimulationMediumOnsite1 report · last Aug 2026
Lowest Common Ancestor in Ordered and Unordered TreesTreeDepth-First SearchMediumPhone1 report · last Aug 2026
String to Integer (atoi)StringParsingMediumOnsite1 report · last Aug 2026
Enumerate Valid Clock TimesArrayBacktrackingEasyOA1 report · last Jul 2026
Minimum Window SubstringStringSliding WindowHardOnsite1 report · last Jul 2026
Binary String Swap TimeStringSimulationMediumOA1 report · last Jul 2026
Minimum Effort Task ScheduleArrayDynamic ProgrammingHardOA1 report · last Jul 2026
Trapping Rain WaterArrayTwo PointersHardOnsite1 report · last Jul 2026
Maximum Pipeline ThroughputBinary SearchGreedyMediumOA1 report · last Jul 2026
Maximum Strong Team SubarrayArrayDynamic ProgrammingMediumOA1 report · last Jul 2026
Alphabetically Smallest PalindromeStringGreedyMediumOA1 report · last Jul 2026
CPU Scheduling SimulatorSimulationQueueMediumOnsite1 report · last Jul 2026
Count Collisions with Ball XArraySimulationEasyPhone1 report · last Jul 2026
Maximum Strength of Every NeuronTreeGraphHardOA1 report · last Jul 2026
Remove Linked List ElementsLinked ListRecursionEasyOnsite1 report · last Jul 2026
Two SumArrayHash TableEasyOnsite1 report · last Jul 2026
Escape Game - Maximize ScoreArrayHash TableMediumOA1 report · last Jul 2026
Palindrome NumberMathEasyOnsite1 report · last Jul 2026
Largest Combination With Bitwise AND Greater Than ZeroArrayBit ManipulationMediumOnsite1 report · last Jun 2026
Binary Tree Level Order TraversalTreeBreadth-First SearchMediumOnsite1 report · last Jun 2026
Minimum Starting Coins to Buy All ProductsArrayGreedyHardOA1 report · last Jun 2026
Minimum Absolute DifferenceArraySortingEasyOnsite1 report · last May 2026
Apply a Sequence of Array RotationsArrayMathMediumOnsite1 report · last May 2026
Rank Open BusinessesArraySortingEasyPhone1 report · last May 2026
Continuous Subarray Sum MultipleArrayHash TableMediumOnsite1 report · last May 2026
Longest Valid ParenthesesStringStackHardOnsite1 report · last May 2026
In-Memory SQL with CSV InitializationDesignParsingHardOnsite1 report · last May 2026
Order Records by Matching Start and EndHash TableLinked ListEasyOnsite1 report · last May 2026
Find All Anagrams in a StringStringSliding WindowMediumOnsite1 report · last Apr 2026
Beam Search and Nucleus DecodingArraySortingHardOnsite1 report · last Apr 2026
Max Points on a LineGeometryHash TableHardOnsite1 report · last Apr 2026
Self-Attention and Causal Masked Self-AttentionMatrixSimulationHardOnsite1 report · last Apr 2026
Maximum Data Transfer TimeTreeDepth-First SearchMediumOA1 report · last Mar 2026
Visible Profiles CountGraphDepth-First SearchMediumOA1 report · last Mar 2026
Inorder Successor in a Binary TreeTreeHardOnsite1 report · last Mar 2026
100 DoorsMathSimulationEasyOnsite1 report · last Mar 2026
Rectangle OverlapMathGeometryEasyOnsite1 report · last Mar 2026
Excel Training Data and Model Response AuditArrayMatrixEasyPhone1 report · last Mar 2026
Redundant ConnectionGraphUnion FindMediumOnsite1 report · last Mar 2026
Fill a Time Window with SongsArrayDynamic ProgrammingMediumOA1 report · last Mar 2026
Recover Corrupted Master PageUnratedOnsite1 report · last Feb 2026
Balanced Permutation SubarraysArrayMediumOA1 report · last Feb 2026
Final Price DiscountArrayStackEasyOA1 report · last Feb 2026
Dog Retrieval Precision and RecallArrayHash TableEasyOnsite1 report · last Feb 2026
Generate ParenthesesStringBacktrackingMediumOnsite1 report · last Feb 2026
Unique Digit Permutations Without Leading ZeroStringMathMediumOnsite1 report · last Feb 2026
Organization Chart by LevelBreadth-First SearchTreeEasyOnsite1 report · last Feb 2026
Resumable Batched Data LoaderArrayHash TableMediumOnsite1 report · last Feb 2026
Streaming Inference Stop Sequence DetectionStringTrieHardOnsite1 report · last Feb 2026
Unique Difference PatternArrayStringEasyOA1 report · last Jan 2026
House RobberArrayDynamic ProgrammingMediumOA1 report · last Jan 2026
Score Difference When Even Picks Reverse the ListArrayTwo PointersEasyOA1 report · last Jan 2026
Add BinaryStringMathEasyOnsite1 report · last Jan 2026
Multiply Without the Multiplication OperatorMathBit ManipulationEasyOnsite1 report · last Jan 2026
Valid SudokuArrayHash TableMediumOnsite1 report · last Jan 2026
Verify Postorder Sequence of a BSTTreeStackMediumOnsite1 report · last Jan 2026
Mean, Median and Mode of a StreamDesignHeapMediumOnsite1 report · last Jan 2026
User and Group Membership IndexHash TableDesignMediumOnsite1 report · last Jan 2026
Integer Square RootMathBinary SearchEasyOnsite1 report · last Dec 2025
Reverse Nodes in k-GroupLinked ListRecursionHardOnsite1 report · last Dec 2025
Validate Binary Search TreeTreeDepth-First SearchMediumOnsite1 report · last Dec 2025
Longest Profit DurationArrayStackMediumOnsite1 report · last Nov 2025
Find Peak ElementArrayBinary SearchMediumOnsite1 report · last Nov 2025
Memory AllocatorDesignArrayMediumOnsite1 report · last Nov 2025
Diagonal Matrix IteratorArrayMatrixMediumOnsite1 report · last Nov 2025
Minimum Path SumArrayDynamic ProgrammingMediumOnsite1 report · last Nov 2025
Gas StationArrayGreedyMediumOnsite1 report · last Oct 2025
Open the LockBreadth-First SearchHash TableMediumOnsite1 report · last Oct 2025
Minimum Size Subarray SumArraySliding WindowMediumOA1 report · last Oct 2025
Distinct Number Line MovesUnratedOA1 report · last Oct 2025
Dijkstra's Shortest PathsGraphShortest PathMediumOnsite1 report · last Oct 2025
Longest Palindrome from Two WordsDynamic ProgrammingStringHardOnsite1 report · last Oct 2025
Union of Two ArraysArrayHash TableEasyOnsite1 report · last Sep 2025
Contains DuplicateArrayHash TableEasyOnsite1 report · last Sep 2025
Merge Two Descending Linked ListsLinked ListTwo PointersEasyOnsite1 report · last Sep 2025
Sort a Linked List in Descending OrderLinked ListSortingMediumOnsite1 report · last Sep 2025
Cut the SticksArraySortingEasyOA1 report · last Sep 2025
Quick SortArraySortingMediumOnsite1 report · last Sep 2025
Remove Redundant Task DependenciesGraphTopological SortMediumOnsite1 report · last Sep 2025
Longest Palindromic Substring LengthStringDynamic ProgrammingMediumOnsite1 report · last Aug 2025
Combination Sum With Unlimited ReuseArrayBacktrackingMediumOnsite1 report · last Aug 2025
Most Frequent CharacterStringHash TableEasyOA1 report · last Aug 2025
Rotate a Square Matrix 90 DegreesArrayMatrixMediumOnsite1 report · last Aug 2025
Make Pixel Columns Strictly IncreasingArrayMatrixEasyOA1 report · last Aug 2025
Smallest Prime at Least NMathEasyOnsite1 report · last Aug 2025
Minimum Round Trip LengthsGraphShortest PathMediumOA1 report · last Aug 2025
Programmer StringsStringSliding WindowMediumOA1 report · last Aug 2025
Merge Two Sorted ListsLinked ListTwo PointersEasyOnsite1 report · last Aug 2025
Find the Intersection Node of Two Linked ListsLinked ListTwo PointersEasyOnsite1 report · last Jul 2025
Generate All String PermutationsStringBacktrackingMediumOnsite1 report · last Jul 2025
Digital Root of a Numeric StringMathStringEasyOnsite1 report · last Jul 2025
Stack with Middle OperationsStackLinked ListMediumOnsite1 report · last Jul 2025
Get Minimum TimeDynamic ProgrammingMatrixMediumOA1 report · last Jun 2025
Count Subarrays with Bitwise OR PresentArrayBit ManipulationHardOA1 report · last Jun 2025
Get Max Or SumArrayBit ManipulationMediumOA1 report · last Jun 2025
Check That Every Node Equals Its Descendant SumTreeDepth-First SearchEasyOnsite1 report · last May 2025
Word LadderStringHash TableHardOnsite1 report · last May 2025
Valid AnagramStringHash TableEasyOnsite1 report · last May 2025
Valid Mixed Case LettersStringHash TableEasyOA1 report · last May 2025
Shortest BridgeMatrixDepth-First SearchMediumOnsite1 report · last May 2025
Equalize Server LatencyTreeGreedyMediumOA1 report · last Apr 2025
Convert a Float to a StringStringMathMediumOnsite1 report · last Apr 2025
Minimum Cars to RemoveArraySliding WindowHardOA1 report · last Apr 2025
Balance the Game BoardStringSimulationMediumOA1 report · last Mar 2025
Maximize Types After Freeing ShelvesSliding WindowHash TableMediumOA1 report · last Mar 2025
Find Upstream Tasks of a Failed TaskGraphBreadth-First SearchEasyOnsite1 report · last Mar 2025
Wildcard Pattern MatchingStringDynamic ProgrammingMediumOnsite1 report · last Mar 2025
Count Characters Before UppercaseStringHash TableEasyOA1 report · last Feb 2025
Maximize Number of Produced CarsArrayBinary SearchMediumOA1 report · last Feb 2025
Minimum Tokens RemainingMathBit ManipulationEasyOA1 report · last Feb 2025
Implement a Self-Balancing BST (AVL Tree)TreeDesignHardOnsite1 report · last Jan 2025
Compressed Representation SizeStringDynamic ProgrammingHardOA1 report · last Jan 2025
Serialize and Deserialize a Binary TreeTreeDepth-First SearchHardOnsite1 report · last Jan 2025
Metro Fare With a Daily CapArraySimulationEasyOA1 report · last Jan 2025
Maximize Sum of Two Non-Overlapping FragmentsArrayPrefix SumHardOA1 report · last Dec 2024
Maximum Sum with TilesDynamic ProgrammingArrayMediumOA1 report · last Dec 2024
Island Perimeter (Round 3, LC 463 :)MatrixSimulationEasyOnsite1 report · last Dec 2024
Word Pattern II (Round 1, LC 291 :)StringBacktrackingMediumOnsite1 report · last Dec 2024
Find Max Sum with Same First and Last DigitArrayHash TableEasyOA1 report · last Dec 2024
Minimum Replacements Required to Make a Matrix BalancedMatrixGreedyHardOA1 report · last Dec 2024
Three Partition ArrayArrayTwo PointersEasyPhone1 report · last Dec 2024
Reverse an IntegerMathEasyOA1 report · last Nov 2024
Maximum Equal Deletion SumDynamic ProgrammingArrayHardOA1 report · last Nov 2024
Maximize Number of Produced CarsArrayBinary SearchMediumOA1 report · last Nov 2024
Sparse Valid One-Dimensional ConvolutionArraySimulationMediumOnsite1 report · last Oct 2024
Calculate Leftover StacksArraySimulationEasyOA1 report · last Oct 2024
Find Minimum CostGreedyMathMediumOA1 report · last Oct 2024
Find Fair IndexesArrayPrefix SumEasyOA1 report · last Oct 2024
Median of Two Sorted ArraysArrayBinary SearchHardOnsite1 report · last Oct 2024
Great SubsequencesDynamic ProgrammingMathHardOA1 report · last Sep 2024
To Good ArraysDynamic ProgrammingCombinatoricsHardOA1 report · last Sep 2024
XOR ColoringBit ManipulationMathHardOA1 report · last Sep 2024
Check Path PresenceGraphHash TableEasyOA1 report · last Sep 2024
Find Suitable LocationsMatrixBreadth-First SearchMediumOA1 report · last Sep 2024
Maximum Number of Moves with Same ResultArrayDynamic ProgrammingMediumOA1 report · last Sep 2024
Minimum Domino RemovalsDynamic ProgrammingArrayMediumOA1 report · last Aug 2024
Shortest Compressed String After RemovalStringDynamic ProgrammingHardOA1 report · last Aug 2024
Product of XOR of All Good PairsArrayBit ManipulationMediumOA1 report · last Aug 2024
Minimize Difference Between Two NumbersGreedyStringHardOA1 report · last Aug 2024
Optimal Path in a GridDynamic ProgrammingMatrixMediumOA1 report · last Aug 2024
Longest Path With Different Adjacent CharactersTreeDepth-First SearchMediumOA1 report · last Jul 2024
Get Alphabetically Smallest StringStringGreedyEasyOA1 report · last Jun 2024
Total Waiting Time for Handmade ItemsArraySimulationMediumOA1 report · last Jun 2024
Maximum CellsMatrixGreedyHardOA1 report · last Jun 2024
The Longest SpikeGreedySortingMediumOA1 report · last May 2024
Find Min Num MovesMatrixGreedyMediumOA1 report · last May 2024
Assign ValuesGraphGreedyMediumOA1 report · last May 2024
Construct Maximum Balanced CircleSortingGreedyHardOA1 report · last May 2024
Frog Game 🐸ArrayTwo PointersMediumOA1 report · last Apr 2024
Minimum Substrings Without Repeating CharactersStringGreedyEasyOA1 report · last Apr 2024
Sort Tuples by Value and Then KeySortingArrayEasyPhone1 report · last Apr 2024
Target-Sum Pair with Two PointersArraySortingEasyPhone1 report · last Apr 2024
Str with Longest LenStringMediumOA1 report · last Mar 2024
Cleaning RobotMatrixSimulationMediumOA1 report · last Mar 2024
Maximum Total Number of Orders FulfilledArraySortingEasyOA1 report · last Mar 2024
The Crazy RulerTreeDepth-First SearchMediumOA1 report · last Mar 2024
Maximizing Difference in Array Elements with Moves 🐹SortingGreedyHardOA1 report · last Feb 2024
Reverse Word Order In PlaceArrayStringMediumPhone1 report · last Jan 2024
Count Similar Substrings (Microsoft India) 🐱StringSliding WindowMediumOA1 report · last Jan 2024
Find Array Uniqueness Median 🐈ArrayBinary SearchHardOA1 report · last Jan 2024
Binary Tree Right Side ViewBreadth-First SearchTreeMediumOnsite1 report · last Oct 2023
Bayesian Posterior From Error RatesMathSimulationMediumPhone1 report · last Dec 2022
Estimate Pi from Uniform SamplesArrayMathEasyOnsite1 report · last Oct 2022
Nearest-Rank Percentile Without SortingArraySortingMediumOnsite1 report · last Oct 2022
Running MediansArrayHeapHardOnsite1 report · last Oct 2022
Uniform Integer from Biased-Coin FlipsMathSimulationHardOnsite1 report · last Oct 2022
Count Set Bits with a Byte Lookup TableArrayBit ManipulationMediumOnsite1 report · last Oct 2022
Wrap Text at 80 CharactersStringGreedyMediumOnsite1 report · last Oct 2022
Gradient Descent for Linear RegressionArrayMathMediumPhone1 report · last Sep 2022
Sum of Distinct Prime DivisorsMathMediumOnsite1 report · last Mar 2022
Detect a Linked-List CycleLinked ListTwo PointersMediumOnsite1 report · last Feb 2022
Generate Character N-Grams from a URLStringSliding WindowEasyPhone1 report · last Feb 2022
Parse a Signed 32-Bit Integer with Overflow DetectionStringMathMediumOnsite1 report · last Feb 2022
Rotate ArrayArrayTwo PointersMediumOnsite1 report · last Feb 2022
Autocomplete Words by PrefixArrayStringEasyOnsite1 report · last Nov 2021
Extra Coin Win ProbabilityMathCombinatoricsEasyPhone1 report · last Nov 2021
Nearest Vocabulary WordStringDynamic ProgrammingMediumOnsite1 report · last Nov 2021
Reservoir Sampling with Supplied Random DrawsArraySimulationMediumOnsite1 report · last Nov 2021
Selected Tree Nodes at the Same Level and HeightTreeDepth-First SearchMediumOnsite1 report · last Nov 2021
Find Duplicate Files by ContentHash TableSortingMediumOnsite1 report · last Nov 2021
Two-Player Gambler's Ruin Probability and SimulationMathDynamic ProgrammingHardOnsite1 report · last Nov 2021
Unique Unordered Dice OutcomesBacktrackingDynamic ProgrammingMediumOnsite1 report · last Oct 2021
New-User Devices That Opened an AppDatabaseEasyOnsite1 report · last Oct 2021
Count Isolated IslandsMatrixDepth-First SearchMediumPhone1 report · last Oct 2021
Monotonic-Run Shuffle ScoreArraySimulationEasyOnsite1 report · last Oct 2021
Check If Two String Arrays Are EquivalentArrayStringEasyOnsite1 report · last Sep 2021
Maximum Sum Increasing SubsequenceArrayDynamic ProgrammingMediumOnsite1 report · last Sep 2021
Observed-User Percentage by AppDatabaseMediumPhone1 report · last Sep 2021
All Unique Two-Sum PairsArrayTwo PointersMediumOnsite1 report · last Mar 2021
Find All Primes Less Than NMathArrayMediumOnsite1 report · last Mar 2021
Even Values at Even IndicesArrayEasyPhone1 report · last Feb 2021
Cascade Deletion of Target-Valued LeavesTreeDepth-First SearchMediumPhone1 report · last Feb 2021
Bold a Visible HTML SubstringStringParsingMediumOnsite1 report · last Dec 2020
Convert a BST to a Doubly Linked ListTreeDepth-First SearchMediumOnsite1 report · last Dec 2020
Factorial Trailing ZeroesMathMediumOnsite1 report · last Dec 2020
Consecutive Number RangesArraySortingMediumPhone1 report · last Dec 2020
First Missing PositiveArrayHash TableHardPhone1 report · last Nov 2020
Duplicate ZerosArrayTwo PointersEasyOnsite1 report · last Nov 2020
Italicize Matching Word RegionsStringArrayMediumOnsite1 report · last Sep 2020
Longest Shared Free Time With One ChangeArraySliding WindowMediumOnsite1 report · last Sep 2020
Categorical Sampling with Recorded DrawsBinary SearchPrefix SumMediumPhone1 report · last Jun 2020
Fibonacci NumberMathDynamic ProgrammingMediumOnsite1 report · last Apr 2020
Softmax Cross-Entropy LossArrayMathMediumOnsite1 report · last Feb 2020
Top K Query SuggestionsStringSortingMediumPhone1 report · last Feb 2020
Print Vertical Asterisk BarsArrayStringEasyOnsite1 report · last Jan 2020
Word Search with Eight-Direction AdjacencyArrayMatrixMediumOnsite1 report · last Jan 2020
Best Time to Buy and Sell StockArrayDynamic ProgrammingEasyOnsiteNot yet reported
Exclusive Time of FunctionsArrayStackMediumOnsiteNot yet reported
Find Pivot IndexArrayPrefix SumEasyOnsiteNot yet reported
Kth Largest Element in an ArrayArrayHeapMediumOnsiteNot yet reported
Longest Common SubsequenceStringDynamic ProgrammingMediumOnsiteNot yet reported
Next Larger Value in a BSTTreeBinary SearchMediumOnsiteNot yet reported
Permutation in StringStringSliding WindowMediumOnsiteNot yet reported
Shuffle With Given Random DrawsArrayMathMediumOnsiteNot yet reported
Split a String by a DelimiterStringParsingEasyOnsiteNot yet reported
Text Editor OperationsStringStackMediumOANot yet reported

At a glance

Microsoft interview process

FastPrep has 345 Microsoft coding interview questions: 127 questions from the online assessment (OA), 37 questions from phone screens and 192 questions from onsite rounds. A question can be reported in more than one stage. Most are medium (207 medium, 86 easy and 50 hard). The most common topics are Array, String, Hash Table, Math and Dynamic Programming. The latest report is from Nov 2026.

  • Online Assessment

    127 questions · 80 medium, 23 easy and 23 hard

    Topics: Array, Greedy and Dynamic Programming

    Latest report: Nov 2026

  • Phone Screen

    37 questions · 17 medium, 13 easy and 7 hard

    Topics: Array, Simulation and Sorting

    Latest report: Nov 2026

  • Onsite

    192 questions · 116 medium, 51 easy and 24 hard

    Topics: Array, String and Hash Table

    Latest report: Nov 2026

By stage and level

Microsoft questions by stage and level

01 · Preparation plan

Connect algorithm correctness to service behavior.

The Microsoft catalog is broad enough to reward deliberate rotation. Start with a parser, move to a dependency problem, and then reason about state over time. Use the separate design collection to extend those implementation choices into service boundaries; do not treat the largest stage group as a prediction of your interview. This is a suggested practice order, not Microsoft's interview process. Your invitation and recruiter come first.

  1. 01

    Parse before calculating

    Use the expression evaluator to separate token recognition from operator precedence. A clear grammar makes nested input easier to reason about than a collection of special cases.

    • Trace parentheses and unary signs before implementing evaluation.
    • Keep tokenization, precedence, and error handling separate.
    • Compare stack depth with the length of the expression.
    Practice: Arithmetic Expression Evaluator
  2. 02

    Make dependency failures explicit

    The employee hierarchy exercise is useful for distinguishing a valid tree from malformed reporting relationships. Explain why cycle detection must happen before computing a reliable depth.

    • Identify roots, disconnected components, and missing parents.
    • Use visiting states to distinguish cycles from completed work.
    • State which depth convention your result uses.
    Practice: Employee Hierarchy Cycle and Depth Analysis
  3. 03

    Test state over time

    Treat the authentication-system exercise as a contract for issuing, renewing, and expiring state. After implementation, use the public service-design exercises to discuss where that state belongs.

    • Define behavior exactly at an expiry boundary.
    • Test repeated renewal and unknown identifiers.
    • Separate storage cleanup from authorization correctness.
    Practice: Authentication System

02 · Design and project questions

52 Microsoft design and project questions

Beyond coding questions, FastPrep has 39 system design and 13 low-level design questions tagged Microsoft.

System designLast reported Nov 2026

Design a Cloud File Storage System

Design a Drive-like service for durable, chunked file storage, sharing, versions, and multi-device synchronization. Audit a first-letter photo placement plan and its database-cost drivers.

Practice
System designLast reported Nov 2026

Design a Personalized Recommendation System

Design event ingestion, candidate retrieval, ranking, and serving for a bounded personalized user-item catalog.

Practice
System designLast reported Nov 2026

Design an Inventory Management Service

Design an authoritative inventory service that supports safe point adjustments and large asynchronous file-based updates.

Practice
System designLast reported Nov 2026

Design an Event-Driven Notification System

Design a reliable multi-channel notification platform for a high-cardinality internal producer fleet, with durable event handoff, fair admission, provider isolation, and recoverable poison messages.

Practice
System designLast reported Nov 2026

Grounded Document-Vault Question Answering

Design a permission-aware RAG service that answers questions over a large document vault with verifiable citations.

Practice
System designLast reported Nov 2026

Design a Cart-to-Order Inventory Platform

Move a cart through checkout and order stages while preventing concurrent inventory oversell.

Practice
Low-level designLast reported Nov 2026

Design an Online Shopping Order Lifecycle

Model order placement with all-or-nothing stock reservation, payment outcomes, and a guarded order state machine.

Practice
System designLast reported Oct 2026

Design a Financial Records Dashboard and History Table

Design the frontend for an internal app where employees check their own financial records: an at-a-glance dashboard and a long, searchable history table that stays fast, honest about partial failures, and fully accessible.

Practice
System designLast reported Oct 2026

Design Learned Web Search Ranking

Learn query-to-link relevance from historical clicks while separating weak feedback, candidate coverage and safe online ranking.

Practice
System designLast reported Oct 2026

Design a Backend Search Engine

Design a multi-tenant backend that ingests versioned documents and serves low-latency text search with filters, stable pagination, and safe index rebuilds.

Practice
System designLast reported Oct 2026

Design a Logging and Data Ingestion System

Accept high-volume log streams, durably buffer them, make recent and historical data queryable, and tail newly arriving records to authorized readers.

Practice
System designLast reported Oct 2026

Design an Online Tic-Tac-Toe Platform

Match two players and execute authoritative turn-based games through retry-safe APIs across multiple regions.

Practice
System designLast reported Oct 2026

Design an Authenticated Shopping Platform

Design a single-retailer shopping API whose login, session, cart, and order boundaries remain secure and retry-safe at scale.

Practice
System designLast reported Oct 2026

Design a Product Page Sharing and Rewards Platform

Design company-managed product pages with trackable share links, anonymous milestone rewards, and trustworthy engagement analytics.

Practice
Low-level designLast reported Oct 2026

Design and Implement an Attack-Path Graph Domain

Model infrastructure assets and typed relationships, then validate and construct traversable attack paths.

Practice
System designLast reported Oct 2026

Design an Employee Attrition Risk Platform

Ingest HR snapshots, train an imbalance-aware attrition model, and deliver auditable explanations to authorized reviewers.

Practice
System designLast reported Sep 2026

Design a Lab Machine Fleet Monitor

Monitor a geographically distributed lab-machine fleet with timely health state, alerts, history, and partition-aware recovery.

Practice
Low-level designLast reported Sep 2026

Design an In-Memory File System

Model an in-memory hierarchical file system with explicit path, entry, listing, and concurrency contracts.

Practice
Low-level designLast reported Sep 2026

Design an Elevator Control System

Model elevator cars, hall and cabin requests, dispatch assignment, movement state, and safe fault handling.

Practice
System designLast reported Sep 2026

Design a Desktop Application Notification System

Coordinate local desktop notifications from multiple applications with durable intent, user policy, bounded delivery, and restart-safe state.

Practice
System designLast reported Sep 2026

Nearby Restaurant Search Service

Design a location search service that returns nearby restaurants in stable distance order.

Practice
System designLast reported Sep 2026

AI Receptionist Voice Chat

Design a voice receptionist that conducts bounded conversations and hands calls to people or workflows.

Practice
System designLast reported Sep 2026

Global One-to-One Voice Calling

Design a globally available service for reliable one-to-one internet voice calls.

Practice
System designLast reported Sep 2026

Design Distributed LLM Embedding and Output Sharding

Shard very large input-embedding and language-model output matrices while controlling memory, communication, skew, and sampling cost.

Practice
Low-level designLast reported Sep 2026

Design and Implement a Highway Toll Session Domain

Model idempotent vehicle entry and exit events, one open journey per vehicle, deterministic toll calculation, and a path to partitioned durable processing.

Practice
Low-level designLast reported Sep 2026

Design and Implement Bank Accounts and Transfers

Model bank accounts and implement safe in-memory transfers, then add an account kind without rewriting the core.

Practice
System designLast reported Aug 2026

Design a Ticket Context and System Status Platform

Design a high-concurrency service that connects a support ticket to related user tickets and the affected system's historical status.

Practice
System designLast reported Aug 2026

Design a Marketplace Product Search Service

Design a large-marketplace search service that filters by price and taxonomy, serves stable ranked pages, and safely incorporates versioned catalog changes.

Practice
System designLast reported Aug 2026

Design a Multi-Tenant One-Time Password Service

Issue, deliver, and verify short-lived one-time passwords while isolating tenant policy, abuse, and data.

Practice
System designLast reported Aug 2026

Design a Web Crawler and Inverted Index

Continuously crawl an allowed web corpus and build a fresh, deduplicated inverted index for keyword search.

Practice
System designLast reported Aug 2026

Design a Distributed Expiring LRU Cache

Design a partitioned cache with concurrent access, per-entry expiration, and approximate local recency eviction.

Practice
System designLast reported Aug 2026

Design Grounded Local Sports Recommendations

Recommend timely local sports coverage with retrieval-grounded summaries, safe fallbacks, and measurable model cost and quality.

Practice
Low-level designLast reported Aug 2026

Desktop Notification Center

Design a desktop notification center with ordering, dismissal, and per-application state.

Practice
Low-level designLast reported Aug 2026

Design a Library Circulation System

Design and implement a library circulation system with titles, physical copies, members, loans, holds, extensible policies, and atomic checkout and return behavior.

Practice
System designLast reported Jul 2026

Design a Real-Time Multiplayer Game

Design a multi-region multiplayer game that matches players and runs low-latency authoritative sessions.

Practice
Low-level designLast reported Jun 2026

Design a Constant-Time Parking Lot

Model a one-row parking lot where parking, parking in a requested spot, leaving and finding a car all take constant time.

Practice
System designLast reported Mar 2026

Design SFT and RL for Consistent LLM Answers

Improve an assistant's factual and abstention consistency across equivalent prompts with reviewed SFT data, reward design, and independent evaluation.

Practice
Low-level designLast reported Mar 2026

Design a Car Rental System with Design Patterns

Model a car rental flow whose pricing rules, car states and notifications can change without rewriting the booking code.

Practice
System designLast reported Feb 2026

Design an Initial Video-Language Model

Design the data, temporal representation, joint training and independent evaluation needed to build a first video-language question-answering model.

Practice
Low-level designLast reported Jan 2026

Design a Tic-Tac-Toe Game

Model a two-player tic-tac-toe game on an n x n board: turns, moves, refused moves, wins and draws.

Practice
System designLast reported Dec 2025

Design Intent Understanding While a User Types

Infer a safe, calibrated task intent from changing partial input without confusing intent with text completion.

Practice
Low-level designLast reported Dec 2025

Design a Stock Exchange with Trader Accounts

Model a small stock exchange: limit orders, price-time matching, partial fills, held cash and shares, and cancellation.

Practice
System designLast reported Nov 2025

Design a Learned Candidate Ranking Service

Design an online ranker and its model lifecycle for caller-supplied candidates.

Practice
System designLast reported Oct 2025

Design RAG-Assisted Kusto Query Generation

Turn an analyst's natural-language question into a grounded, authorized Kusto query with a safe preview path.

Practice
System designLast reported Oct 2025

Optimize LLM Inference Across Model and Infrastructure

Improve the latency and unit cost of an existing streaming LLM service while protecting answer quality and safe rollout.

Practice
System designLast reported Sep 2025

Design an AR Lens Creator and Publishing Platform

Let creators upload AR camera lens projects, build them into small phone-ready packages in the background, publish them, and let camera users find and download them quickly.

Practice
System designLast reported Apr 2024

Design Budgeted AutoML Model Selection

Automatically compare reproducible tabular classification pipelines, select a model, and enforce a finite search budget despite retries and worker failures.

Practice
System designLast reported Oct 2022

Design Website Classification with Crowd-Labeled Data

Classify websites from domain and page signals while measuring crowd-label quality and protecting minority classes.

Practice
System designLast reported Oct 2021

Design Semantic Ad Retrieval and Ranking

Retrieve and rank relevant text and image ads for a query while learning safely from sparse, biased feedback.

Practice
Low-level designLast reported Sep 2020

Design and Implement a Thread-Safe LRU Cache

Build a bounded in-memory cache that preserves exact least-recently-used eviction when several threads share it.

Practice
System designLast reported Sep 2020

Design a Self-Driving Perception Model

Build, evaluate, and release an object-detection model for cars, bicycles, and trucks under severe scenario and class imbalance.

Practice
System designLast reported Feb 2020

Design a Spreadsheet Next-Command Recommender

Predict useful next spreadsheet commands from an ordered session history without leaking future actions or exposing private workbook content.

Practice

03 · About these questions

Where these Microsoft questions come from

Each question on this page is tagged Microsoft in FastPrep's problem bank. The report count and month show how often and how recently it was reported from Microsoft interviews.

Past reports help you choose what to practice first. They can't tell you which questions, format or platform your own interview will use.

  • Only questions tagged Microsoft appear on this page.
  • Each coding question shows its stage and last report date when known.
  • These are not official, private or leaked Microsoft questions.

04 · FAQ

Microsoft interview questions: FAQ

For hiring news and timelines, see the Microsoft hiring insights page.

01What are the stages of the Microsoft interview?

The 345 Microsoft coding questions on FastPrep come from the online assessment (127 questions), phone screens (37 questions) and onsite rounds (192 questions). Some questions were reported in more than one stage. Stages differ by role, level and date, so check your invitation for your own process.

02What does the Microsoft OA look like?

127 of the 345 Microsoft coding questions on FastPrep come from the online assessment. By difficulty: 80 medium, 23 easy and 23 hard. Common OA topics: Array, Greedy and Dynamic Programming. The latest OA report is from Nov 2026.

03How hard is the Microsoft interview?

Most Microsoft coding questions on FastPrep are medium. By difficulty, the 343 rated questions are 207 medium, 86 easy and 50 hard.

04What topics come up in Microsoft coding interviews?

Across 345 Microsoft coding questions, the most common topics are Array (147 questions), String (84 questions), Hash Table (65 questions), Math (58 questions) and Dynamic Programming (50 questions).

05What are the most asked Microsoft interview questions?

The most reported questions are “Least Recently Used Cache” (12 reports), “Maximum Escape Game Score” (7 reports) and “Authentication System” (6 reports).

06Should I prepare only Microsoft assessment questions?

No. The available practice spans timed coding, explanation-heavy problems, and design exercises. Use assessment-labeled records for implementation rehearsal, then switch to dependencies and stateful APIs when your role calls for discussion. This is a software-engineering study path, not a guide to every Microsoft role or a fixed sequence of rounds.

07Is FastPrep affiliated with Microsoft?

No. FastPrep is an independent interview prep site and is not affiliated with Microsoft. These are practice questions from FastPrep's problem bank, not official, private or leaked Microsoft questions.

08How do you know which stage a Microsoft question is from?

Each question's stage comes from the reports behind it. A question can be reported from more than one stage, and the process can change by role, level, location and year, so treat the stage as a guide, not a promise.

09Which Microsoft interview stage should I practice first?

The stage named in your invitation or recruiter message. If you don't know the stage yet, start with the stage that has the most questions, then practice explaining and testing your code out loud.

10Can this page tell me exactly what my Microsoft interview will ask?

No. Report counts, stages and dates show what came up before and help you choose what to practice first. They can't predict the questions, order, timing or platform of your own interview.

Next step

Pick a question. Solve it end to end.

Start with the stage named in your invitation. Past reports show what came up before, not what you will be asked.

Back to the question list