Mathworks logo MA
Verified Company Vault

Mathworks DSA Interview Questions

31 curated coding interview questions directly asked in Mathworks technical rounds, sorted by frequency with recency and difficulty diagnostics.

31 Total Questions
6 (19%) Easy Problems
15 (48%) Medium Problems
10 (32%) Hard Problems
🔥 Most Tested Topics:
Arrays (10)Strings (9)Core DSA (8)Trees (5)Graphs (2)
📂 Sourced Datasets:
Last 6 monthsAll questionsOlder than 6 months
Showing 31 of 31 displayed
IDProblemDifficultyTopicPatternAcceptanceFrequencyRecency
2918Minimum Equal Sum of Two Arrays After Replacing ZerosMediumArraysSorting / Prefix / Scan50.2%100.0%6m
2861Maximum Number of AlloysMediumArraysSorting / Prefix / Scan41.0%100.0%all
566Reshape the MatrixEasyArraysSorting / Prefix / Scan65.0%100.0%all
3035Maximum Palindromes After OperationsMediumArrays; StringsSorting / Prefix / Scan; Hashing / Sliding Window46.5%100.0%all
2462Total Cost to Hire K WorkersMediumCore DSAImplementation / Reasoning43.6%100.0%all
1648Sell Diminishing-Valued Colored BallsMediumCore DSAImplementation / Reasoning30.2%100.0%all
1220Count Vowels PermutationHardBacktrackingBacktracking61.3%87.5%6m
2514Count AnagramsHardStringsHashing / Sliding Window37.7%87.5%all
2038Remove Colored Pieces if Both Neighbors are the Same ColorMediumCore DSAImplementation / Reasoning63.1%87.5%all
1163Last Substring in Lexicographical OrderHardStrings; Trees; GraphsHashing / Sliding Window; DFS / BFS; BFS / DFS / Topological Sort35.0%87.5%all
1130Minimum Cost Tree From Leaf ValuesMediumArrays; TreesSorting / Prefix / Scan; DFS / BFS67.9%87.5%all
3049Earliest Second to Mark Indices IIHardCore DSAImplementation / Reasoning22.6%87.5%all
3048Earliest Second to Mark Indices IMediumCore DSAImplementation / Reasoning36.9%87.5%all
2444Count Subarrays With Fixed BoundsHardArraysSorting / Prefix / Scan69.2%87.5%all
500Keyboard RowEasyCore DSAImplementation / Reasoning73.9%87.5%all
2582Pass the PillowEasyCore DSAImplementation / Reasoning56.6%87.5%all
968Binary Tree CamerasHardTreesDFS / BFS47.9%87.5%all
638Shopping OffersMediumCore DSAImplementation / Reasoning52.5%87.5%all
2858Minimum Edge Reversals So Every Node Is ReachableHardArrays; TreesSorting / Prefix / Scan; DFS / BFS59.5%75.0%all
621Task SchedulerMediumGreedyGreedy63.1%75.0%all
2851String TransformationHardStringsHashing / Sliding Window27.2%62.5%all
25Reverse Nodes in k-GroupHardTrees; Linked ListDFS / BFS; Two Pointers66.1%62.5%all
2964Number of Divisible Triplet SumsMediumArraysSorting / Prefix / Scan67.6%62.5%all
1328Break a PalindromeMediumStringsHashing / Sliding Window51.6%50.0%all
1290Convert Binary Number in a Linked List to IntegerEasyLinked ListTwo Pointers82.4%50.0%all
1335Minimum Difficulty of a Job ScheduleHardArraysSorting / Prefix / Scan59.8%50.0%all
2559Count Vowel Strings in RangesMediumStringsHashing / Sliding Window67.8%50.0%all
2831Find the Longest Equal SubarrayMediumArraysSorting / Prefix / Scan38.1%50.0%all
2697Lexicographically Smallest PalindromeEasyStrings; GraphsHashing / Sliding Window; BFS / DFS / Topological Sort81.4%50.0%all
20Valid ParenthesesEasyStringsHashing / Sliding Window44.2%50.0%all
3335Total Characters in String After Transformations IMediumStringsHashing / Sliding Window45.6%50.0%all