Microsoft Interview Experience | On-Campus for Internship
Round 1: Online Coding Test
I was in my T.Y. B.Tech. (Sem 5), when Microsoft visited our campus for offering 2 months summer internship.
First Round was online coding test on CoCubes Platform. Difficulty level of questions were easy to medium. 3 Coding questions were to be solved. Questions Were
- A Number plate problem where only odd and even number plate vehicles can go out on a weekday. Given numbers of vehicle and schedule of odd/even on weekday, find maximum number of vehicles that can go out on a day.
- A problem based on BFS of Graph. Similar to Rotten Oranges Problem.
- Given a Singly Linked List, Reverse the linked list in place using O(1) space.
Some Other Questions were
- Reverse a Linked List in groups of size K
- Some traversal problem based on BST and graph.
Nearly 25 students passed this round.
Round 2: On Paper Coding Round
Groups were formed and each group was assigned a mentor. We were supposed to explain the approach of problems given to our mentor and code on paper. Questions Were :
- Check if a given Binary tree is a BST without using extra space.
- Finding second maximum element of the array.
- Find Depth of BST.
I found inorder traversal of the tree for first problem but no extra space was to be used. I reduced the space complexity to O(1) but time complexity was O(n). I found depth of BST using Recursion.
Nearly 15 students were selected for Face to Face interviews. I was one of them.
Round 3: Face to Face Interview – 1
Questions asked during my interview were :
- Write on paper code for Binary Search
- Implement a Queue data structure using Stack data structure.
- Write a code to heapify a array. It was basically a Heap Data Structure problem but I messed up here.
- Asked about Dynamic Programming and a question to find longest palindromic subsequence.
- ACID property of DBMS.
Only 5 people cleared this round and I was rejected after this.