Microsoft Interview Experience for Fresher SDE - 1, Nov 2019
Online Coding Test
This round was the online coding test conducted on the platform Mettl. The languages allowed were C, C++, Java and Python. There were three questions. One was of graphs (Depth-first search), other was a big integer problem and the third was a string problem.
You are given a graph with N vertices numbered from 1 to N and M edges. You have to colour this graph in two different colours, say Blue and Red such that no two vertices connected by an edge is of same colour.
You are given an array consisting of 'N' integers. You have to find the fourth largest element present in the array.
Write a program to do basic string compression. For a character which is consecutively repeated more than once, replace consecutive duplicate occurrences with the count of repetitions.
For e.g. if a String has 'x' repeated 5 times, replace this "xxxxx" with "x5".
Just be confident during interview and if you are stuck in between any question, then ask for a hint from the interviewer. The practice is key for success, so practice hard for Data Structures and Algorithms coding problems on Coding ninjas as it is the best platform for coding. Also you may practice on Geeks For Geeks or any other interview portal.
Mention all internships which you have done, as it increases your chances of shortlisting your resume. Also just write that skills which you are pretty confident about.
For any off campus application, I'd suggest getting a referral first before applying.