## Microsoft Interview Experience | Set 159 (On campus)

Round 1: The first round consisted of two coding questions to be solved in 1 hr – Given a binary tree, print the boundary of… Read More »

- Count total ways to reach destination from source in an undirected Graph
- Paranthesis Theorem
- Count nodes in the given tree whose weight is a fibonacci number
- Find a Mother vertex in a Graph using Bit Masking
- Minimum time required to visit all the special nodes of a Tree
- Minimum Cost of Simple Path between two nodes in a Directed and Weighted Graph
- Count of distinct colors in a subtree of a Colored Tree with given min frequency for Q queries
- Count of different groups using Graph
- Count of elements which form a loop in an Array according to given constraints
- Lowest Common Ancestor for a Set of Nodes in a Rooted Tree
- Minimum labelled node to be removed from undirected Graph such that there is no cycle
- Find dependencies of each Vertex in a Directed Graph
- Maximum weighted edge in path between two nodes in an N-ary tree using binary lifting
- Find GCD of each subtree of a given node in an N-ary Tree for Q queries
- Largest subarray sum of all connected components in undirected graph
- Count the nodes in the given Tree whose weight is a Perfect Number
- Largest component size in a graph formed by connecting non-co-prime nodes
- Count of unique lengths of connected components for an undirected graph using STL
- Minimum Bipartite Groups
- Count of nodes having odd divisors in the given subtree for Q queries
- Minimum value of distance of farthest node in a Graph
- Find the maximum component size after addition of each edge to the graph
- Count ways to change direction of edges such that graph becomes acyclic
- Count the number of walks of length N where cost of each walk is equal to a given number
- Minimum valued node having maximum depth in an N-ary Tree
- Size of the Largest Trees in a Forest formed by the given Graph
- Check if vertex X lies in subgraph of vertex Y for the given Graph
- Octal equivalents of connected components in Binary valued graph
- Print the nodes of the Binary Tree whose height is a Prime number
- Count of leaf nodes of the tree whose weighted string is a palindrome

Round 1: The first round consisted of two coding questions to be solved in 1 hr – Given a binary tree, print the boundary of… Read More »

Count the total number of ways or paths that exist between two vertices in a directed graph. These paths don’t contain a cycle, the simple… Read More »

We are given a matrix that contains different values in its each cell. Our aim is to find the minimal set of positions in the… Read More »

Given a number n. we need to print all N digit pattern formed by mobile Keypad. Note: we can move up, down, left, right from… Read More »

Given Binary matrix. Task is count all zeros which are surrounded by one (may not be immediate neighbor). Note: here we are only taking four… Read More »

Given n friends and their friendship relations, find the total number of groups that exist. And the number of ways of new groups that can… Read More »

A tree is always a Bipartite Graph as we can always break into two disjoint sets with alternate levels. In other words we always color… Read More »

Given two numbers n and k and you have to find all possible combination of k numbers from 1…n. Examples: Input : n = 4… Read More »

The diameter of a tree (sometimes called the width) is the number of nodes on the longest path between two leaves in the tree. The… Read More »

Given a tree in the form of adjacency list we have to calculate the number of nodes in the subtree of each node while calculating… Read More »

Given a string of characters of length less than 10. We need to print all the alpha-numeric abbreviation of the string. The alpha-numeric abbreviation is… Read More »

A directed acyclic graph (DAG) is a graph which doesn’t contain a cycle and has directed edges. We are given a DAG, we need to… Read More »

Senior android Developer Coding Round: Spirally traversing a matrix Longest Increasing Subsequence First Round: find “longest line” of 1’s in array. Hoizontal and Vertical. Array… Read More »

Given a directed tree with V vertices and V-1 edges, we need to choose such a root (from given nodes from where we can reach… Read More »

Given a weighting scale and an array of different positive weights where we have an infinite supply of each weight. Our task is to put… Read More »