Upload Button Icon Add office photos

Microsoft Corporation

Compare button icon Compare button icon Compare

Proud winner of ABECA 2024 - AmbitionBox Employee Choice Awards

zig zag pattern zig zag pattern

Filter interviews by

Microsoft Corporation Interview Questions, Process, and Tips for Freshers

Updated 8 Apr 2025

Top Microsoft Corporation Interview Questions and Answers for Freshers

View all 207 questions

Microsoft Corporation Interview Experiences for Freshers

Popular Designations

126 interviews found

Intern Interview Questions & Answers

user image PrepInsta

posted on 17 Nov 2021

I applied via Referral and was interviewed in Sep 2021. There were 3 interview rounds.

Round 1 - Online Assessment 

(2 Questions)

Round duration - 90 minutes
Round difficulty - null
Online test consisted of two questions which we had to solve in 90 minutes. It was conducted on Codility.

  • Q1. Reverse the order of words in a given sentence(an array of characters)
  • Ans. 

    To reverse the order of words in a given sentence, we need to split the sentence into words and then reverse the order of the resulting array.

    • Split the sentence into words using a delimiter like space or comma

    • Reverse the resulting array of words

    • Join the reversed array of words using a delimiter to form the reversed sentence

  • Answered by AI
  • Q2. Given N people of an M*M grid, find the point that requires the least total distance by all people to meet at that point.
  • Ans. 

    Given N people on an M*M grid, find the point with the least total distance for all to meet.

    • Calculate the Manhattan distance for each point on the grid

    • Find the point with the minimum total distance

    • Use dynamic programming to optimize the solution

    • Consider edge cases such as when N=1 or M=1

  • Answered by AI
Round 2 - Interview 

(2 Questions)

Round duration - 50 minute
Round difficulty - null
This was also a coding round. The interviewer gave me two questions that I had to code.

  • Q1. Number of islands problem
  • Ans. 

    The number of islands problem involves counting the number of connected islands in a grid.

    • An island is a group of connected 1s in a grid of 0s and 1s.

    • Use depth-first search or breadth-first search to traverse the grid and count the islands.

    • Keep track of visited cells to avoid counting the same island multiple times.

  • Answered by AI
  • Q2. Scope resolution program
  • Ans. 

    Scope resolution program is used to determine the scope of a variable in a program.

    • It helps in identifying the location of a variable in a program

    • It helps in avoiding naming conflicts between variables

    • It can be done using the dot operator or the arrow operator in object-oriented programming

    • It can also be done using the scope resolution operator (::) in C++

  • Answered by AI
Round 3 - Interview 

(3 Questions)

This was a theoretical round. The Interviewer asked me questions about my college and discipline.

  • Q1. Explain your final year project.
  • Ans. 

    Developed a mobile app for tracking and managing personal finances.

    • Used React Native for cross-platform development

    • Implemented features such as budget tracking, expense categorization, and bill reminders

    • Integrated with third-party APIs for real-time stock market data

    • Conducted user testing and implemented feedback for improved user experience

  • Answered by AI
  • Q2. What type of difficulties you faced while creating the project?
  • Ans. 

    I faced difficulties in managing the project timeline and coordinating with team members.

    • Coordinating with team members who were working remotely

    • Managing the project timeline and ensuring timely delivery

    • Dealing with unexpected technical issues and bugs

    • Ensuring the project met the client's requirements and expectations

  • Answered by AI
  • Q3. A binary tree type question
  • Ans. 

    A binary tree is a data structure in which each node has at most two children.

    • Binary trees are used in computer science for efficient searching and sorting algorithms.

    • Examples of binary trees include binary search trees, AVL trees, and red-black trees.

    • Traversal methods for binary trees include in-order, pre-order, and post-order traversal.

    • Binary trees can also be used to represent hierarchical data, such as file system

  • Answered by AI

Interview Preparation Tips

Professional and academic backgroundAt the time of the interview, I had 0 Years (fresher) of experience.Microsoft interview preparation:Topics to prepare for the interview - I read Interview Experiences of candidates and got an idea of the questions that come. Microsoft deals with coding questions only, and their questions are all advanced level programming, so I prepared accordingly. I read about Dynamic programming.Resources to prepare for this interview - I was following PrepInsta’s coding classes on Youtube and discord. Their questions are
really good and the way they explain the logic was also helpful. Through the discord community I received a one month prime subscription. Using that I studied there coding courses, which were of great help.Tips for other job seekers - Prepare the coding questions well. Also whatever you have mentioned in your resume read some questions on those as they will cross check you.Final outcome of the interviewSelected

Skills evaluated in this interview

Top Microsoft Corporation Intern Interview Questions and Answers

Q1. Reverse the order of words in a given sentence(an array of characters)
View answer (1)

Intern Interview Questions asked at other Companies

Q1. Case. There is a housing society “The wasteful society”, you collect all the household garbage and sell it to 5 different businesses. Determine what price you will pay to the society members in Rs/kg, given you want to make a profit of 20% ... read more
View answer (8)

I appeared for an interview in Apr 2021.

Round 1 - Coding Test 

(1 Question)

Round duration - 90 minutes
Round difficulty - Hard

  • Q1. 

    Stock Buying and Selling Problem Statement

    Given an array of stock prices where each element represents the stock price for a given day, determine the maximum profit you can achieve from buying and sellin...

  • Ans. 

    Determine maximum profit from buying and selling stocks on different days.

    • Iterate through the array of stock prices and calculate the profit for each pair of days.

    • Keep track of the maximum profit obtained by selling and buying stocks on different days.

    • Return the maximum profit achieved.

  • Answered by AI
Round 2 - Video Call 

(1 Question)

Round duration - 40 Minutes
Round difficulty - Medium

  • Q1. 

    Time to Burn Tree Problem

    You are given a binary tree consisting of 'N' unique nodes and a start node where the burning will commence. The task is to calculate the time in minutes required to completely b...

  • Ans. 

    Calculate the time in minutes required to completely burn a binary tree starting from a given node.

    • Perform a depth-first search (DFS) to calculate the time taken to burn the entire tree.

    • Track the time taken for each node to catch fire and burn the tree accordingly.

    • Consider the adjacency of nodes to determine the spread of fire.

    • Handle cases where the start node is at different levels in the tree.

    • Optimize the solution to

  • Answered by AI
Round 3 - Face to Face 

(1 Question)

Round duration - 40 minutes
Round difficulty - Easy

  • Q1. 

    Flatten Binary Tree Problem Statement

    Given a binary tree consisting of integer values, your task is to convert the binary tree into a linked list where the nodes of the linked list follow the same order ...

  • Ans. 

    Convert a binary tree into a linked list following pre-order traversal order.

    • Perform pre-order traversal of the binary tree and convert it into a linked list.

    • Use the right pointer of the binary tree as the 'next' pointer for the linked list.

    • Set the left pointer to NULL for each node in the linked list.

    • Example: Input - 1 2 3 4 -1 5 6 -1 7 -1 -1 -1 -1 -1 -1, Output - 1 2 4 7 3 5 6

  • Answered by AI
Round 4 - Video Call 

(2 Questions)

Round duration - 25 Minutes
Round difficulty - Hard

  • Q1. Can you provide a code example that demonstrates communication between two processes?
  • Ans. 

    Demonstrate communication between two processes using inter-process communication (IPC) methods.

    • Use sockets for communication between two processes running on the same or different machines.

    • Implement message passing using shared memory or message queues.

    • Utilize pipes for communication between parent and child processes.

  • Answered by AI
  • Q2. 

    Gray Code Problem Statement

    You are given a number grayNumber. Your task is to find and return the Gray code sequence.

    Explanation

    The Gray code sequence should satisfy the following conditions:

    1. Inc...
  • Ans. 

    Find and return the Gray code sequence for a given number.

    • Generate Gray code sequence by following the conditions provided in the problem statement.

    • Ensure that consecutive numbers in the sequence differ by exactly 1 bit.

    • Start the sequence with 0 and include numbers up to 2^grayNumber - 1.

    • Return the sequence in decimal form as a list/vector.

    • If multiple valid sequences exist, return any of them.

  • Answered by AI

Interview Preparation Tips

Professional and academic backgroundI applied for the job as SDE - 1 in HyderabadEligibility criteriaNo criteriaMicrosoft interview preparation:Topics to prepare for the interview - DBMS, Data Structures and Algorithms , OOP, Maths puzzles, Aptitude , CN, OSTime required to prepare for the interview - 9 MonthsInterview preparation tips for other job seekers

Tip 1 : Never leave any topic from any chapter / Subject
Tip 2 : Learn to explain your thoughts well
Tip 3 : Learn from previous experiences / interviews / problems asked.
Tip 4 : Atleast 4 projects in Resume

Application resume tips for other job seekers

Tip 1 : Atleast 4 projects on Resume
Tip 2 : Do not write false things. You always get caught. Be genuine.

Final outcome of the interviewSelected

Skills evaluated in this interview

Top Microsoft Corporation Software Developer Interview Questions and Answers

Q1. Buses Origin Problem Statement You have been provided with an array where each element specifies the number of buses that can be boarded at each respective bus stop. Buses will only stop at locations that are multiples of the bus stop they ... read more
View answer (4)

Software Developer Interview Questions asked at other Companies

Q1. Maximum Subarray Sum Problem Statement Given an array of integers, determine the maximum possible sum of any contiguous subarray within the array. Example: Input: array = [34, -50, 42, 14, -5, 86] Output: 137 Explanation: The maximum sum is... read more
View answer (43)

I appeared for an interview in Apr 2021.

Round 1 - Coding Test 

(3 Questions)

Round duration - 90 minutes
Round difficulty - Easy

There were 3 coding questions. All of them were pretty easy and solvable in less than 30 minutes. Some string and pattern matching + some number theory problems were there.

  • Q1. 

    Arithmetic Expression Evaluation Problem Statement

    You are provided with a string expression consisting of characters '+', '-', '*', '/', '(', ')' and digits '0' to '9', representing an arithmetic express...

  • Ans. 

    Evaluate arithmetic expressions in infix notation with given operators and precedence rules.

    • Parse the infix expression to postfix using a stack.

    • Evaluate the postfix expression using a stack.

    • Handle operators precedence and parentheses while evaluating.

    • Ensure no division by zero cases and operands fit in 32-bit integer.

  • Answered by AI
  • Q2. 

    Maximum Product Subarray Problem Statement

    Given an array of integers, determine the contiguous subarray that produces the maximum product of its elements.

    Explanation:

    A subarray can be derived from th...

  • Ans. 

    Find the contiguous subarray with the maximum product of elements in an array.

    • Iterate through the array and keep track of the maximum and minimum product ending at each index.

    • Update the maximum product by taking the maximum of current element, current element * previous maximum, and current element * previous minimum.

    • Update the minimum product by taking the minimum of current element, current element * previous maximum...

  • Answered by AI
  • Q3. 

    Angle Calculation Between Clock Hands

    Given a specific time in hours and minutes, your task is to calculate the smallest possible angle between the hour hand and the minute hand of a clock.

    Example:

    Inp...
  • Ans. 

    Calculate the smallest angle between the hour and minute hands of a clock given a specific time.

    • Calculate the angle formed by the hour hand with respect to 12 o'clock position

    • Calculate the angle formed by the minute hand with respect to 12 o'clock position

    • Find the absolute difference between the two angles and take the minimum of the two possible angles

    • Return the floor value of the calculated angle

  • Answered by AI
Round 2 - Face to Face 

(2 Questions)

Round duration - 45 minutes
Round difficulty - Medium

This was a technical round. First after properly introducing ourselves(me and the interviewer), we started with the main interview. I was asked 2 questions, one DS and Algorithms and the other System Design question.

  • Q1. 

    Problem Statement: Sibling Nodes

    You are provided with a Binary Tree consisting of 'N' nodes, where each node holds an integer value. Your objective is to identify and list all nodes that do not possess a...

  • Ans. 

    Identify and list nodes in a Binary Tree that do not have a sibling.

    • Traverse the Binary Tree in level order and keep track of nodes without siblings.

    • Check if each node has a sibling by comparing with its parent's other child.

    • Output the values of nodes without siblings in ascending order.

    • Handle cases where the root node is considered a sibling node.

  • Answered by AI
  • Q2. Design an elevator system for a single building with N floors.
  • Ans. 

    Design an elevator system for a single building with N floors.

    • Create a data structure to track the current floor of the elevator and the requested floors.

    • Implement algorithms for elevator movement such as FIFO, SCAN, or LOOK.

    • Consider factors like peak hours, weight capacity, and emergency situations.

    • Include features like door open/close buttons, emergency stop button, and floor selection panel.

  • Answered by AI

Interview Preparation Tips

Professional and academic backgroundI applied for the job as SDE - Intern in BangaloreEligibility criteriaNo criteriaMicrosoft interview preparation:Topics to prepare for the interview - Data Structures and Algorithms problems with Trees, Graphs, stack etc. Basic System Designing. Database Management System and SQL queries. Operation System and Process Scheduling techniques.Time required to prepare for the interview - 8 monthsInterview preparation tips for other job seekers

Tip 1 : Make sure to solve the most recommended problems of LeetCode. Around 200 will do
Tip 2 : Be confident with your basics of chapters from Operating Systems and DBMS or SQL Queries.
Tip 3 : Have a slight knowledge of system designing concepts.

Application resume tips for other job seekers

Tip 1 : Make your Resume such that it is properly readable. Keep it of one page. If it exceeds try your best to include only the most important highlights.
Tip 2 : Put your most important achievements at the top and after than the not so important ones. You want the interviewer to see them first.

Final outcome of the interviewSelected

Skills evaluated in this interview

Top Microsoft Corporation Software Developer Intern Interview Questions and Answers

Q1. Mean, Median, Mode Calculation You are given an array 'ARR' consisting of 'N' integers. Your task is to calculate the three statistical measures for the given array: Mean - Implement the function mean() to calculate the mean of the array. ... read more
View answer (1)

Software Developer Intern Interview Questions asked at other Companies

Q1. Sum of Maximum and Minimum Elements Problem Statement Given an array ARR of size N, your objective is to determine the sum of the largest and smallest elements within the array. Follow Up: Can you achieve the above task using the least numb... read more
View answer (5)
Interview experience
4
Good
Difficulty level
Moderate
Process Duration
4-6 weeks
Result
Selected Selected

I applied via Company Website and was interviewed before Oct 2022. There were 4 interview rounds.

Round 1 - Resume Shortlist 
Pro Tip by AmbitionBox:
Keep your resume crisp and to the point. A recruiter looks at your resume for an average of 6 seconds, make sure to leave the best impression.
View all tips
Round 2 - Coding Test 

Dynamic programming, Graph, Hashing

Round 3 - Coding Test 

1 Coding Problem
Questions on Projects and DBMS, OS, OOPS.

Round 4 - HR 

(1 Question)

  • Q1. Behavioural Questions

Software Engineer Intern Interview Questions asked at other Companies

Q1. Check if Two Trees are Mirror Given two arbitrary binary trees, your task is to determine whether these two trees are mirrors of each other. Explanation: Two trees are considered mirror of each other if: The roots of both the trees are the... read more
View answer (1)

Microsoft Corporation interview questions for popular designations

 Software Engineer

 (65)

 Software Developer

 (63)

 Senior Software Engineer

 (28)

 Software Developer Intern

 (24)

 Intern

 (20)

 Technical Support Engineer

 (14)

 Software Development Engineer

 (11)

 Data Scientist

 (10)

Interview Questions & Answers

user image Anonymous

posted on 23 Aug 2022

I appeared for an interview in Dec 2021.

Round 1 - Resume Shortlist 
Pro Tip by AmbitionBox:
Keep your resume crisp and to the point. A recruiter looks at your resume for an average of 6 seconds, make sure to leave the best impression.
View all tips
Round 2 - Coding Test 

It was on hacker rankdckjd cjd cjkd ckjdc

Round 3 - HR 

(2 Questions)

  • Q1. Why you want to join our company
  • Q2. Why you not want to join that comapny

Interview Preparation Tips

Topics to prepare for Microsoft Corporation interview:
  • Mysql
  • Nosql
  • Yoursql
  • NoneSQL
Interview preparation tips for other job seekers - if the coin and the new off the medium and new if you add me in the data and of the suer

Get interview-ready with Top Microsoft Corporation Interview Questions

I appeared for an interview in Jan 2021.

Round 1 - Coding Test 

(1 Question)

Round duration - 90 minutes
Round difficulty - Medium

it was around 9 :30 am interviewer was friendly

  • Q1. 

    Find All Triplets with Zero Sum

    Given an array Arr consisting of N integers, find all distinct triplets in the array that sum up to zero.

    Explanation:

    An array is said to have a triplet {Arr[i], Arr[j],...

  • Ans. 

    Find all distinct triplets in an array that sum up to zero.

    • Use a nested loop to iterate through all possible combinations of triplets.

    • Sort the array to easily identify duplicates and skip unnecessary calculations.

    • Use two-pointer technique to find the remaining element for each pair of elements.

  • Answered by AI
Round 2 - Video Call 

(2 Questions)

Round duration - 60 Minutes
Round difficulty - Medium

morning 11 am 
interviewer was friendly

  • Q1. 

    Generate Binary Strings from Pattern

    Given a string STR containing '0', '1', and '?' special characters, generate all possible strings by replacing each '?' with either '0' or '1'.

    Input:

    The first line...
  • Ans. 

    Generate all possible binary strings by replacing '?' with '0' or '1'.

    • Iterate through the input string and replace '?' with '0' and '1' recursively to generate all possible strings.

    • Use backtracking to explore all possible combinations.

    • Sort the generated strings lexicographically before returning the final result.

  • Answered by AI
  • Q2. 

    Sum Root to Leaf Numbers

    You are given an arbitrary binary tree consisting of N nodes, each associated with an integer value from 1 to 9. Each root-to-leaf path can be considered a number formed by concat...

  • Ans. 

    Calculate the total sum of all root to leaf paths in an arbitrary binary tree.

    • Traverse the tree in a depth-first manner to calculate the sum of each root to leaf path.

    • Keep track of the current path sum and update it as you traverse the tree.

    • Return the total sum modulo (10^9 + 7) as the final result.

  • Answered by AI
Round 3 - Video Call 

(1 Question)

Round duration - 45 Minutes
Round difficulty - Hard

it was around 3
good recieving of interviewer

  • Q1. 

    The Celebrity Problem

    Imagine there are 'N' people at a party, each assigned a unique ID from 0 to N-1. A celebrity at the party is a person who is known by everyone but knows no one else.

    Problem Statem...

  • Ans. 

    Identify the celebrity at a party where one person knows everyone but is not known by anyone.

    • Use a two-pointer approach to eliminate non-celebrity candidates.

    • Start with two pointers at the beginning and end of the party.

    • If A knows B, A cannot be the celebrity; move A to the right.

    • If A does not know B, B cannot be the celebrity; move B to the left.

    • Repeat until only one person remains, check if this person is known by ev...

  • Answered by AI
Round 4 - Video Call 

Round duration - 50 Minutes
Round difficulty - Easy

it was arround 2 afternoon

Interview Preparation Tips

Professional and academic backgroundI completed Computer Science Engineering from National Institute of Technology Patna. I applied for the job as SDE - 1 in HyderabadEligibility criteriaNo criteriaMicrosoft interview preparation:Topics to prepare for the interview - data structure and algorithm, operating system, dbms, networks, oops, back trackingTime required to prepare for the interview - 6 monthsInterview preparation tips for other job seekers

Tip 1 : Prepare for common interview questions
Tip 2 : Practice, practice, practice.
It's one thing to come prepared with a mental answer to a question like, "Why should we hire you?" It's another challenge entirely to say it out loud in a confident and convincing way. The first time you try it, you'll sound garbled and confused, no matter how clear your thoughts are in your own mind! Do it another 10 times, and you'll sound a lot smoother and more articulate.
But you shouldn't do your practicing when you're "on stage" with a recruiter; rehearse before you go to the interview. The best way to rehearse? Get two friends and practice interviewing each other in a "round robin": one person acts as the observer and the "interviewee" gets feedback from both the observer and the "interviewer." Go for four or five rounds, switching roles as you go. Another idea (but definitely second-best) is to tape record your answer and then play it back to see where you need to improve. Whatever you do, make sure your practice consists of speaking aloud. Rehearsing your answer in your mind won't cut it.
 

Application resume tips for other job seekers

Tip 1 : Should have different projects
Tip 2 : Internships in good companies

Final outcome of the interviewSelected

Skills evaluated in this interview

Top Microsoft Corporation Software Developer Interview Questions and Answers

Q1. Buses Origin Problem Statement You have been provided with an array where each element specifies the number of buses that can be boarded at each respective bus stop. Buses will only stop at locations that are multiples of the bus stop they ... read more
View answer (4)

Software Developer Interview Questions asked at other Companies

Q1. Maximum Subarray Sum Problem Statement Given an array of integers, determine the maximum possible sum of any contiguous subarray within the array. Example: Input: array = [34, -50, 42, 14, -5, 86] Output: 137 Explanation: The maximum sum is... read more
View answer (43)

I appeared for an interview in Jan 2021.

Round 1 - Coding Test 

(2 Questions)

Round duration - 75 minutes
Round difficulty - Hard

This round was scheduled in the evening hours and all the participants were required to fill a form which was shared 2 days prior to the test date. This form was filled out probably for the security reasons and to ensure that no one disinterested participant gives the test.

  • Q1. 

    Validate BST Problem Statement

    Given a binary tree with N nodes, determine whether the tree is a Binary Search Tree (BST). If it is a BST, return true; otherwise, return false.

    A binary search tree (BST)...

  • Ans. 

    Validate if a given binary tree is a Binary Search Tree (BST) or not.

    • Check if the left subtree of a node contains only nodes with data less than the node's data.

    • Check if the right subtree of a node contains only nodes with data greater than the node's data.

    • Ensure that both the left and right subtrees are also binary search trees.

  • Answered by AI
  • Q2. 

    Longest Palindromic Subsequence Problem Statement

    Given a string A consisting of lowercase English letters, determine the length of the longest palindromic subsequence within A.

    Explanation:

    • A subsequ...
  • Ans. 

    Find the length of the longest palindromic subsequence in a given string.

    • Use dynamic programming to solve this problem efficiently.

    • Create a 2D array to store the lengths of palindromic subsequences for different substrings.

    • Fill the array diagonally based on the characters in the string.

    • Return the length of the longest palindromic subsequence for each test case.

  • Answered by AI
Round 2 - HR 

Round duration - 45 minutes
Round difficulty - Medium

There was only one female interviewer for this round. She continuously interacted with me and was giving me some good situational problems that were not very easy to answer. Basically those were open-minded questions which can be answered both ways and that's why I found it quiet hard as per my nature but at the end things went well for me.

Interview Preparation Tips

Professional and academic backgroundI completed Computer Science Engineering from Malaviya National Institute of Technology Jaipur. I applied for the job as SDE - Intern in HyderabadEligibility criteriaComputer science and it's related branchMicrosoft interview preparation:Topics to prepare for the interview - Data Structures and Algorithms, OOPS, System Design, DBMS, Operating System, Pointers, HashingTime required to prepare for the interview - 7 monthsInterview preparation tips for other job seekers

Tip 1 : Practice all DSA questions from interview bit
Tip 2 : Do Atleast 3 project one should be major, if it's in web dev it would be beneficial.
Tip 3 : Should be good in communication skills

Application resume tips for other job seekers

Tip 1 : Not more than 1 page
Tip 2 : Have atleast 3 projects with some achievement in coding contest and your coding handle should be mentioned like codechef, codeforces etc
Tip 3 : Try to keep only those things in resume in which you find yourself comfortable with

Final outcome of the interviewSelected

Skills evaluated in this interview

Top Microsoft Corporation Software Developer Intern Interview Questions and Answers

Q1. Mean, Median, Mode Calculation You are given an array 'ARR' consisting of 'N' integers. Your task is to calculate the three statistical measures for the given array: Mean - Implement the function mean() to calculate the mean of the array. ... read more
View answer (1)

Software Developer Intern Interview Questions asked at other Companies

Q1. Sum of Maximum and Minimum Elements Problem Statement Given an array ARR of size N, your objective is to determine the sum of the largest and smallest elements within the array. Follow Up: Can you achieve the above task using the least numb... read more
View answer (5)

I appeared for an interview in May 2021.

Round 1 - Face to Face 

(2 Questions)

Round duration - 60 Minutes
Round difficulty - Medium

2 coding questions were asked

  • Q1. 

    Count Squares in a Matrix

    Given a matrix of size N * M, your task is to count the number of squares present within it.

    Since the count can be extremely large, the result should be computed modulo 109 + 7...

  • Ans. 

    Count the number of squares in a given matrix modulo 10^9 + 7.

    • Iterate through all possible square sizes from 1 to min(N, M)

    • For each square size, count the number of squares that can fit in the matrix

    • Return the total count modulo 10^9 + 7

  • Answered by AI
  • Q2. 

    First Missing Positive Problem Statement

    You are provided with an integer array ARR of length 'N'. Your objective is to determine the first missing positive integer using linear time and constant space. T...

  • Ans. 

    Find the smallest positive integer missing from an array of integers.

    • Iterate through the array and mark positive integers as visited by changing the sign of the corresponding index.

    • After marking all positive integers, iterate again to find the first positive integer with a positive value.

    • Return the index of the first positive integer found plus one as the answer.

  • Answered by AI
Round 2 - Face to Face 

(1 Question)

Round duration - 100 Minutes
Round difficulty - Medium

There was 1 coding question, and questions on CN, DBMS, OS and system design and also my resume.

  • Q1. 

    Remove K Digits Problem Statement

    You are given a non-negative integer represented as a string num and an integer k. Your task is to determine the smallest possible integer by removing exactly k digits fr...

  • Ans. 

    Given a non-negative integer as a string and an integer k, find the smallest possible integer after removing k digits.

    • Use a stack to keep track of the digits in non-decreasing order from left to right.

    • Pop elements from the stack if the current digit is smaller than the top of the stack and k is greater than 0.

    • Handle edge cases like leading zeros and ensuring the final result is not an empty string.

    • Example: For num = "1...

  • Answered by AI
Round 3 - Face to Face 

(1 Question)

Round duration - 40 Minutes
Round difficulty - Medium

Interviewer was quite experienced he asked me 1 coding question and asked questions about college and resume

  • Q1. 

    Longest Duplicate Substring Problem Statement

    You are provided with a string 'S'. The task is to determine the length of the longest duplicate substring within this string. Note that duplicate substrings ...

  • Ans. 

    Find the length of the longest duplicate substring in a given string.

    • Use binary search to find the length of the longest duplicate substring.

    • Implement Rabin-Karp algorithm for efficient substring search.

    • Consider using a rolling hash function for substring comparisons.

  • Answered by AI

Interview Preparation Tips

Professional and academic backgroundI applied for the job as SDE - 1 in BangaloreEligibility criteria8 CGPAMicrosoft interview preparation:Topics to prepare for the interview - Linked List, Binary Search, Dynammic Programming, Two pointer, Hashmap and heap,OOPS, Stack and QueuesTime required to prepare for the interview - 6 MonthsInterview preparation tips for other job seekers

Tip 1 : Try to cover all most common questions of all topics(atleast 300+ questions)
Tip 2 : Try to see as many interview experience as possible of the company you are applying.
Tip 3 : Try to give atleast 2-3 mock interview before main interview

Application resume tips for other job seekers

Tip 1 : Try to put competitive programming ranks if possible or Coding Ninjas Certificate, or any proof that you do programming regularly.
Tip 2 : Try to add atleast 2 projects, and study about those projects well.

Final outcome of the interviewSelected

Skills evaluated in this interview

Top Microsoft Corporation Software Developer Interview Questions and Answers

Q1. Buses Origin Problem Statement You have been provided with an array where each element specifies the number of buses that can be boarded at each respective bus stop. Buses will only stop at locations that are multiples of the bus stop they ... read more
View answer (4)

Software Developer Interview Questions asked at other Companies

Q1. Maximum Subarray Sum Problem Statement Given an array of integers, determine the maximum possible sum of any contiguous subarray within the array. Example: Input: array = [34, -50, 42, 14, -5, 86] Output: 137 Explanation: The maximum sum is... read more
View answer (43)

I appeared for an interview in Dec 2020.

Round 1 - Coding Test 

(3 Questions)

Round duration - 60 Minutes
Round difficulty - Easy

There were 3 coding questions of various difficulty level

  • Q1. 

    LRU Cache Design Question

    Design a data structure for a Least Recently Used (LRU) cache that supports the following operations:

    1. get(key) - Return the value of the key if it exists in the cache; otherw...

  • Ans. 

    Design a Least Recently Used (LRU) cache data structure that supports get and put operations with capacity constraint.

    • Implement a doubly linked list to maintain the order of keys based on their recent usage.

    • Use a hashmap to store key-value pairs for quick access and update.

    • When capacity is reached, evict the least recently used item before inserting a new item.

    • Update the order of keys in the linked list whenever a key ...

  • Answered by AI
  • Q2. 

    Minimum Operations Problem Statement

    You are given an array 'ARR' of size 'N' consisting of positive integers. Your task is to determine the minimum number of operations required to make all elements in t...

  • Ans. 

    Determine minimum operations to make all array elements equal using addition, subtraction, multiplication, or division.

    • Iterate through array to find the maximum and minimum elements.

    • Calculate the difference between maximum and minimum elements.

    • The minimum number of operations needed is the difference between the maximum and minimum elements.

  • Answered by AI
  • Q3. 

    N Queens Problem

    Given an integer N, find all possible placements of N queens on an N x N chessboard such that no two queens threaten each other.

    Explanation:

    A queen can attack another queen if they ar...

  • Ans. 

    The N Queens Problem involves finding all possible placements of N queens on an N x N chessboard without threatening each other.

    • Use backtracking algorithm to explore all possible configurations

    • Check if the current placement is safe by verifying rows, columns, and diagonals

    • Print valid configurations where queens do not attack each other

  • Answered by AI
Round 2 - Video Call 

(3 Questions)

Round duration - 80 Minutes
Round difficulty - Easy

Asked various coding questions and their implementations

  • Q1. 

    Number of Islands Problem Statement

    You are provided with a 2-dimensional matrix having N rows and M columns, containing only 1s (land) and 0s (water). Your goal is to determine the number of islands in t...

  • Ans. 

    Count the number of islands in a 2D matrix of 1s and 0s.

    • Use Depth First Search (DFS) or Breadth First Search (BFS) to traverse the matrix and identify connected groups of 1s.

    • Maintain a visited array to keep track of visited cells to avoid redundant traversal.

    • Increment the island count each time a new island is encountered.

  • Answered by AI
  • Q2. 

    Reverse Stack with Recursion

    Reverse a given stack of integers using recursion. You must accomplish this without utilizing extra space beyond the internal stack space used by recursion. Additionally, you ...

  • Ans. 

    Reverse a given stack of integers using recursion without using extra space or loops.

    • Use recursion to pop all elements from the original stack and store them in function call stack.

    • Once the stack is empty, push the elements back in reverse order using recursion.

    • Make use of the top(), pop(), and push() stack methods provided.

    • Example: If the input stack is [1, 2, 3], after reversal it should be [3, 2, 1].

  • Answered by AI
  • Q3. 

    Pair Sum Problem Statement

    You are given an integer array 'ARR' of size 'N' and an integer 'S'. Your task is to find and return a list of all pairs of elements where each sum of a pair equals 'S'.

    Note:
    ...
  • Ans. 

    Find pairs of elements in an array that sum up to a given value, sorted in a specific order.

    • Iterate through the array and for each element, check if the complement (S - current element) exists in a set.

    • If the complement exists, add the pair to the result list.

    • Sort the result list based on the criteria mentioned in the problem statement.

  • Answered by AI
Round 3 - HR 

Round duration - 30 Minutes
Round difficulty - Easy

HR was very friendly

Interview Preparation Tips

Professional and academic backgroundI applied for the job as SDE - Intern in BengaluruEligibility criteria8 cgpaMicrosoft interview preparation:Topics to prepare for the interview - Data Structures, Arrays, Backtracking, Pointers, OOPS, System Design, Greedy Algorithms, Dynamic Programming, Trees and graphs,Time required to prepare for the interview - 3 monthsInterview preparation tips for other job seekers

Tip 1 : Don't lie over your resume
Tip 2 : Practice regularly
Tip 3 : Revision is the key

Application resume tips for other job seekers

Tip 1 : Right only correct info, Don't fake it
Tip 2 : Keep it precise and concise.

Final outcome of the interviewSelected

Skills evaluated in this interview

Top Microsoft Corporation Software Developer Intern Interview Questions and Answers

Q1. Mean, Median, Mode Calculation You are given an array 'ARR' consisting of 'N' integers. Your task is to calculate the three statistical measures for the given array: Mean - Implement the function mean() to calculate the mean of the array. ... read more
View answer (1)

Software Developer Intern Interview Questions asked at other Companies

Q1. Sum of Maximum and Minimum Elements Problem Statement Given an array ARR of size N, your objective is to determine the sum of the largest and smallest elements within the array. Follow Up: Can you achieve the above task using the least numb... read more
View answer (5)

I appeared for an interview in Dec 2020.

Round 1 - Coding Test 

(2 Questions)

Round duration - 120 Minutes
Round difficulty - Easy

Total 3 coding questions were there, out of which I don't remember the last one.

  • Q1. 

    Ninja's Dance Competition Pairing Problem

    Ninja is organizing a dance competition and wants to pair participants using a unique method. Each participant chooses a number upon entry, and Ninja selects a nu...

  • Ans. 

    Find the number of distinct pairs of participants with a given difference in their chosen numbers.

    • Iterate through the list of numbers and check for pairs with the required difference 'K'.

    • Use a hash set to keep track of unique pairs to avoid counting duplicates.

    • Return the size of the hash set as the number of distinct pairs.

  • Answered by AI
  • Q2. 

    Longest Common Prefix After Rotation

    You are given two strings 'A' and 'B'. While string 'A' is constant, you may apply any number of left shift operations to string 'B'.

    Explanation:

    Your task is to calcu...

  • Ans. 

    Calculate minimum left shift operations to achieve longest common prefix between two strings.

    • Apply left shift operations to string B to find longest common prefix with string A

    • Count number of shifts needed to achieve longest common prefix

    • Handle circular rotation of characters in string B

    • Return minimum number of left shift operations for each test case

  • Answered by AI
Round 2 - Video Call 

(2 Questions)

Round duration - 60 Minutes
Round difficulty - Easy

  • Q1. 

    Rotate Matrix by 90 Degrees Problem Statement

    Given a square matrix 'MATRIX' of non-negative integers, rotate the matrix by 90 degrees in an anti-clockwise direction using only constant extra space.

    Inpu...

  • Ans. 

    Rotate a square matrix by 90 degrees in an anti-clockwise direction using constant extra space.

    • Iterate through each layer of the matrix from outer to inner layers

    • Swap elements in groups of 4 to rotate the matrix

    • Handle odd-sized matrices separately by adjusting the loop boundaries

  • Answered by AI
  • Q2. 

    Problem: Sort an Array of 0s, 1s, and 2s

    Given an array/list ARR consisting of integers where each element is either 0, 1, or 2, your task is to sort this array in increasing order.

    Input:

    The input sta...
  • Ans. 

    Sort an array of 0s, 1s, and 2s in increasing order.

    • Use a three-pointer approach to partition the array into sections for 0s, 1s, and 2s.

    • Iterate through the array and swap elements based on their values and the pointers.

    • After sorting, the array will have 0s at the beginning, followed by 1s, and then 2s.

  • Answered by AI
Round 3 - Video Call 

(1 Question)

Round duration - 60 Minutes
Round difficulty - Easy

This was HR + Technical round
He started with questions on projects and Os and Dbms and Oops
Then asked one coding question

  • Q1. 

    Number of Islands Problem Statement

    You are given a non-empty grid that consists of only 0s and 1s. Your task is to determine the number of islands in this grid.

    An island is defined as a group of 1s (re...

  • Ans. 

    The task is to determine the number of islands in a grid of 0s and 1s connected horizontally, vertically, or diagonally.

    • Iterate through the grid and perform depth-first search (DFS) to find connected 1s forming islands

    • Mark visited cells to avoid counting the same island multiple times

    • Count the number of islands found during DFS traversal

  • Answered by AI

Interview Preparation Tips

Professional and academic backgroundI applied for the job as SDE - Intern in HyderabadEligibility criteria7 cgpaMicrosoft interview preparation:Topics to prepare for the interview - Data Structures and Algorithms, DBMS, Java, Computer Networks, Operating Systems, OopsTime required to prepare for the interview - 6 monthsInterview preparation tips for other job seekers

Tip 1 : Maintain At least 2 projects in your resume.
Tip 2 : Be Confident enough 
Tip 3 : Solve lot of problems

Application resume tips for other job seekers

Tip 1 : Achievements are good to have
Tip 2 : You should be able to answer all the questions related to skills in the resume.

Final outcome of the interviewSelected

Skills evaluated in this interview

Top Microsoft Corporation Software Developer Intern Interview Questions and Answers

Q1. Mean, Median, Mode Calculation You are given an array 'ARR' consisting of 'N' integers. Your task is to calculate the three statistical measures for the given array: Mean - Implement the function mean() to calculate the mean of the array. ... read more
View answer (1)

Software Developer Intern Interview Questions asked at other Companies

Q1. Sum of Maximum and Minimum Elements Problem Statement Given an array ARR of size N, your objective is to determine the sum of the largest and smallest elements within the array. Follow Up: Can you achieve the above task using the least numb... read more
View answer (5)

Microsoft Corporation Interview FAQs

How many rounds are there in Microsoft Corporation interview for freshers?
Microsoft Corporation interview process for freshers usually has 2-3 rounds. The most common rounds in the Microsoft Corporation interview process for freshers are Coding Test, Technical and Resume Shortlist.
How to prepare for Microsoft Corporation interview for freshers?
Go through your CV in detail and study all the technologies mentioned in your CV. Prepare at least two technologies or languages in depth if you are appearing for a technical interview at Microsoft Corporation. The most common topics and skills that interviewers at Microsoft Corporation expect are microsoft, Internship, Machine Learning, Computer science and Research.
What are the top questions asked in Microsoft Corporation interview for freshers?

Some of the top questions asked at the Microsoft Corporation interview for freshers -

  1. You have a cuboid (m*n*p) each block of the cuboid is having a metallic ball. ...read more
  2. Given a string of containing lower case letters and upper case characters. Find...read more
  3. Suppose you have an array of elements which has duplicates except 1 number, ex....read more
How long is the Microsoft Corporation interview process?

The duration of Microsoft Corporation interview process can vary, but typically it takes about less than 2 weeks to complete.

Tell us how to improve this page.

Microsoft Corporation Interview Process for Freshers

based on 50 interviews

Interview experience

4.3
  
Good
View more

Interview Questions from Similar Companies

Oracle Interview Questions
3.7
 • 864 Interviews
Google Interview Questions
4.4
 • 842 Interviews
Amdocs Interview Questions
3.7
 • 517 Interviews
Zoho Interview Questions
4.3
 • 512 Interviews
SAP Interview Questions
4.2
 • 284 Interviews
Adobe Interview Questions
3.9
 • 235 Interviews
Salesforce Interview Questions
4.0
 • 230 Interviews
24/7 Customer Interview Questions
3.5
 • 176 Interviews
View all

Microsoft Corporation Reviews and Ratings

based on 1.8k reviews

4.0/5

Rating in categories

3.8

Skill development

4.0

Work-life balance

3.8

Salary

3.5

Job security

4.0

Company culture

3.4

Promotions

3.7

Work satisfaction

Explore 1.8k Reviews and Ratings
Software Engineer
2.2k salaries
unlock blur

₹15 L/yr - ₹51 L/yr

Senior Software Engineer
1.2k salaries
unlock blur

₹25 L/yr - ₹95 L/yr

Software Engineer2
1.1k salaries
unlock blur

₹21.1 L/yr - ₹72 L/yr

Software Developer
880 salaries
unlock blur

₹14.3 L/yr - ₹51 L/yr

Support Engineer
601 salaries
unlock blur

₹9 L/yr - ₹30 L/yr

Explore more salaries
Compare Microsoft Corporation with

Google

4.4
Compare

Amazon

4.0
Compare

Deloitte

3.8
Compare

TCS

3.7
Compare
Did you find this page helpful?
Yes No
write
Share an Interview