Morgan Stanley Coding Interview Questions: 29 Tagged Problems
29 coding problems tagged Morgan Stanley — 8 easy · 17 medium · 4 hard — with solutions in 13 languages. Plus a 3-week study plan by topic.
- Problems: 29
- By difficulty: 8 easy · 17 medium · 4 hard
- Languages: JavaScript, TypeScript, Python, Java, C++, C, C#, Go, Kotlin, Swift, Rust, PHP and Ruby
- Cost: Free on every plan; sign in to run and submit
29 problems the CodeKairo catalogue tags as commonly asked in Morgan Stanley's coding rounds — 8 easy, 17 medium and 4 hard — each judged by hidden tests in 13 languages. The most common topics among them are Arrays (24), Dynamic Programming (10) and Hash Table (6). Tagged for Morgan Stanley and no other company: Find Subarrays With Equal Sum, Jump Game and Maximum Product Subarray. CodeKairo's Morgan Stanley — Aptitude & Technical mock covers the Morgan Stanley aptitude and technical assessment pattern, where computer science carries most of the weight: thirty of its fifty-three questions are fundamentals. The tag is the catalogue's own annotation of where a problem tends to come up — not a list published by Morgan Stanley, which CodeKairo is not affiliated with.
Morgan Stanley study plan by topic
All 29 problems tagged Morgan Stanley over 3 weeks, about 15 h 55 min of solving, grouped by technique in the order they build on each other — Arrays, Hash Table, Math and Two Pointers and 14 more. It ends with the Morgan Stanley — Aptitude & Technical mock.
Week 1: Arrays, Hash Table, Math +5
12 problems on Arrays, Hash Table, Math, Two Pointers, Sliding Window, Prefix Sum, Stack and Queue, easiest first within each topic.
- The Employee That Worked on the Longest Task Easy
- Two Sum Easy
- Find Subarrays With Equal Sum Easy
- Palindrome Number Easy
- Remove Duplicates from Sorted Array Easy
- Sort Colors Medium
- Longest Substring Without Repeating Characters Medium
- Subarrays with K Different Integers Hard
- Find The Original Array of Prefix Xor Medium
- Longest Valid Parentheses Hard
- First Unique Character in a String Easy
- Count Subarrays With Fixed Bounds Hard
Week 2: Monotonic Stack, Simulation, Intervals +5
10 problems on Monotonic Stack, Simulation, Intervals, Greedy, Divide and Conquer, Quickselect, Heap and Graph, easiest first within each topic.
- Daily Temperatures Medium
- Spiral Matrix Medium
- Merge Intervals Medium
- Minimum Cost to Move Chips to The Same Position Easy
- Jump Game Medium
- Candy Hard
- Maximum Subarray Medium
- Kth Largest Element in an Array Medium
- Number of Orders in the Backlog Medium
- Minimum Swaps to Sort Medium
Week 3: Dynamic Programming, Game Theory
7 problems on Dynamic Programming and Game Theory, easiest first within each topic.
- Best Time to Buy and Sell Stock Easy
- Maximum Product Subarray Medium
- Delete and Earn Medium
- 0/1 Knapsack Medium
- Longest Common Substring Medium
- Maximum Sum Increasing Subsequence Medium
- Optimal Strategy For A Game Medium
Finally: the timed test
Sit the Morgan Stanley — Aptitude & Technical mock under the clock — the coding problems are only one part of the round.
Morgan Stanley test patterns
- Morgan Stanley — Aptitude & Technical pattern guide and timed mock
The Morgan Stanley interview process, round by round
All problems tagged Morgan Stanley
Easy (8)
- Find Subarrays With Equal Sum Array, Hash Table
- The Employee That Worked on the Longest Task Array
- Minimum Cost to Move Chips to The Same Position Array, Math, Greedy
- First Unique Character in a String Hash Table, String, Queue
- Remove Duplicates from Sorted Array Array, Two Pointers
- Best Time to Buy and Sell Stock Array, Dynamic Programming
- Palindrome Number Math
- Two Sum Array, Hash Table
Medium (17)
- Maximum Sum Increasing Subsequence Array, Dynamic Programming
- Optimal Strategy For A Game Array, Dynamic Programming, Game Theory
- Longest Common Substring String, Dynamic Programming
- 0/1 Knapsack Array, Dynamic Programming
- Number of Orders in the Backlog Array, Simulation, Heap (Priority Queue)
- Find The Original Array of Prefix Xor Bit Manipulation, Array, Prefix Sum
- Minimum Swaps to Sort Array, Sorting, Graph
- Delete and Earn Array, Hash Table, Dynamic Programming
- Merge Intervals Array, Sorting, Intervals
- Spiral Matrix Array, Matrix, Simulation
- Kth Largest Element in an Array Array, Heap, Quickselect
- Jump Game Array, Greedy, Dynamic Programming
- Daily Temperatures Array, Stack, Monotonic Stack
- Sort Colors Array, Two Pointers, Sorting
- Longest Substring Without Repeating Characters String, Sliding Window, Hash Table
- Maximum Product Subarray Array, Dynamic Programming
- Maximum Subarray Array, Dynamic Programming, Divide and Conquer
Hard (4)
- Count Subarrays With Fixed Bounds Array, Sliding Window, Two Pointers
- Subarrays with K Different Integers Array, Hash Table, Sliding Window
- Longest Valid Parentheses String, Dynamic Programming, Stack
- Candy Array, Greedy
Topics Morgan Stanley asks most
- Arrays 24 problems
- Dynamic Programming 10 problems
- Hash Table 6 problems
- Strings 4 problems
- Two Pointers 4 problems
- Sorting 4 problems
- Sliding Window 3 problems
- Greedy 3 problems
- Counting 2 problems
- Math 2 problems
- Stack 2 problems
- Queue 2 problems