Skip to content
Related Articles

Related Articles

Improve Article

Microsoft Interview experience | Set 98 (On Campus for IDC)

  • Difficulty Level : Easy
  • Last Updated : 28 Jun, 2021

Round 1 : (1hr 15 min)

Online test on CoCubes contains 3 Coding Questions

  1. Calculate difficulty of a given sentence. Where difficulty of a word is:
    Word is hard if it has 4 consecutive consonants or number of consonants are more than number of vowels else word is easy. Difficulty of sentence is defined as 5*(number of hard words) + 3*(number of easy words).
    Solution: GeeksforGeeks Link
  2.  Linked list is given where a node has x and y value. You have to calculate changes in slope. So if m1 is slope between p1 & p2 and m2 is slope between p2 & p3 then if m1 is not equal to m2 then there is a change in slope. Total number of changes in slope were expected as return value.
  3.  Find the sum of all nodes that have no child at minimum level. Return -1 if root is NULL

    Example –

        5
       / 
      2   6
     /  /
    7 3  9 4
    / 
    8 3
    

    Answer: 14 (7+3+4)

    After this round 8 students were selected for direct interview and 22 for group fly round. They asked two coding questions related to strings and trees in group fly round.

Round 2 (Group-fly):
Was called directly for round 3.

Round 3 (Technical Interview):
The interviewer asked me 6 technical questions for which he helped me getting the most optimized approach.



  1. Write a C program to calculate pow(x,n).
    But he asked me not to use recursion.
  2. Detect and remove loop from a Linked List. I was asked to count the nodes in loop as well.
  3. Connect nodes present at the same level. Asked me to do it without queues.

I can’t recall the rest questions.
Then he asked me a simple DBMS design question. I had to implement student and subjects relation. Then asked me to normalize the schema. He also asked some theory questions from OS and DBMS.

Round 4 (Technical Interview):
The Interviewer asked me 3 coding questions and a lot of theory questions from DBMS and OS. Determine if two rectangles overlap or not. If they do, then separate them in a given size of screen. The program should print appropriate message if separation is not possible. He basically wanted a mathematical approach. He also asked all the possible orientation of the rectangles.

  1. Maximum Path sum in a Binary Tree. I couldn’t give a proper solution, so he changed the question to find the maximum sum path with or without including root and leaf.
  2. Check if given Tic – Tac- Toe configuration is valid or not .  He wanted me to handle all the edge cases.

The interviewer helped wherever I got stuck.

Round 5 (AA):

The interviewer asked me to implement strtok() function.
Then he asked me to implement first reader’s problem. This round was very chill. Interviewer helped me wherever he could. He then asked a few HR questions.

After this 3 got selected as FTE’s Overall, the experience was nice. And the interviewers were friendly. Thanks GeeksForGeeks!!

If you like GeeksforGeeks and would like to contribute, you can also write an article and mail your article to review-team@geeksforgeeks.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.

Please write comments if you find anything incorrect, or you want to share more information about the topic discussed above

Attention reader! Don’t stop learning now. Get hold of all the important DSA concepts with the DSA Self Paced Course at a student-friendly price and become industry ready. To complete your preparation from learning a language to DS Algo and many more, please refer Complete Interview Preparation Course. In case you are prepared, test your skills using TCS, Wipro, AmazonGoogle and Microsoft Test Serieses.

My Personal Notes arrow_drop_up
Recommended Articles
Page :