Microsoft Internship Interview Experience | On-Campus 2021
Round 1(Online Coding Test): Round 1 was an online coding test held on Codility. It had two coding questions as follows:
- The first question was an easy problem based on dice rolling. You are given a total number of dice rolls T and a total sum TotalSum to achieve. K of those T rolls have been performed and the sum is CurrentSum. Your goal is to return the values of the remaining rolls such that your net sum is TotalSum.
- The second question was similar to https://www.geeksforgeeks.org/count-minimum-number-of-fountains-to-be-activated-to-cover-the-entire-garden/.
About 40 students were shortlisted for the face-to-face interviews. All the rounds were mostly DSA based.
Round 2(Coding Interview): Round 2 was a 45-minute coding interview with two coding questions. I had to first explain my approach before coding out my solution. The questions are as follows:
- https://www.geeksforgeeks.org/diameter-of-a-binary-tree/. I was able to code out the optimal solution. We discussed the possible test cases and the interviewer was satisfied with my answer.
- Given a string of alphabets, find the Kth smallest lexicographic character in it. I discussed the sorting approach and then explained my O(n) solution using Hashmaps. He asked me a follow-up question to find the Kth smallest character in between various L and R positions. The expected solution was preprocessing in O(n) and O(1) to fetch solutions for each L, R pair. (I was unable to code this solution due to insufficient time.)
About 30 people were shortlisted for the next round.
Round 3(Coding Interview): Round 3 was a coding interview similar to Round 2.
- https://www.geeksforgeeks.org/search-element-sorted-matrix/. I was able to implement and code out my binary search solution.
- https://leetcode.com/problems/regular-expression-matching/. I discussed my DP solution and explained the approach for various test cases. (Did not code this solution due to time constraints.)
About 20 people were shortlisted for the next round.
Round 4(HR and Technical Interview): The interview began with a brief discussion on my projects and the challenges faced.
- I was asked a question on OS which I attempted but informed him that I have not learned it yet. He then asked me to design a phone log given phone numbers and their timestamps. The features were: Add a new call detail; Retrieve the top X most frequent calls in the past Y hours.
- I did not have much idea and came up with a solution but it wasn’t very optimal. This interview is just to judge how you think and your approach to complex problems.
The results were announced after 4 hours and 16 people were selected for a summer internship at Microsoft.
Some tips for preparation:
- Be familiar with every concept and ensure you code the solution and not just read it.
- Check out company-based questions on platforms like GeeksforGeeks and Interviewbit and try to solve them before looking at the solution.
- Use a combination of sources like Leetcode, GeeksforGeeks, Hackerrank, etc, and set a 30-45 minute time limit to solve each question.
- Have some good coding projects on your resume and ensure you can explain your contribution to it properly.
- Try to keep talking to your interviewer and explain your thought process clearly.
- Stay calm before and during the interview.
All the best and happy coding!!
Hey geek! It’s time to become a success story instead of reading them. Check out our most renowned DSA Self Paced Course, now at a student-friendly price and become industry ready. And if you are looking for a more complete interview preparation resource, check out Complete Interview Preparation Course that will prepare you for the SDE role of your dreams!
Feeling prepared enough for your interview? Test your skills with our Test Series that will help you prepare for top companies like Amazon, Microsoft, TCS, Wipro, Google and many more!