Morgan-Stanley Topics for Interview Preparation

    Easy Level


  1. Bubble Sort
  2. Count numbers from 1 to n that have 4 as a a digit
  3. Heap Sort
  4. Largest even number possible by using one swap operation in given number
  5. Minimum number of distinct elements after removing m items
  6. QuickSort
  7. Remove duplicates from sorted array
  8. Swap Kth node from beginning with Kth node from end in a Linked List
  9. Write your own atoi()
  10. Count ways to reach the n'th stair
  11. Dynamic Programming | Set 10 ( 0-1 Knapsack Problem)
  12. Dynamic Programming | Set 14 (Maximum Sum Increasing Subsequence)
  13. Find day of the week for a given date
  14. Find the minimum element in a sorted and rotated array
  15. Find minimum number of coins that make a given value
  16. Find next greater number with same set of digits
  17. Greedy Algorithms | Set 1 (Activity Selection Problem)
  18. Largest subarray with equal number of 0s and 1s
  19. Maximum Product Subarray
  20. Print a given matrix in spiral form
  21. Reverse words in a given string
  22. Sort a linked list of 0s, 1s and 2s
  23. Sort an array of 0s, 1s and 2s
  24. Write a function to reverse a linked list

Medium Level


  1. Check if a number is Bleak
  2. Dynamic Programming | Set 7 (Coin Change)
  3. Greedy Algorithms | Set 3 (Huffman Coding)
  4. Largest Sum Contiguous Subarray

Hard Level


  1. Median in a stream of integers (running integers)







Company Wise Coding Practice    Topic Wise Coding Practice