Skip to content

Tag Archives: Microsoft

Given a singly linked list, find the middle of the linked list. For example, if the given linked list is 1->2->3->4->5 then the output should… Read More
Two trees are identical when they have same data and arrangement of data is also same. To identify if two trees are identical, we need… Read More
You are given a list of n-1 integers and these integers are in the range of 1 to n. There are no duplicates in the… Read More
The very first solution that comes to our mind is the one that we learned in school. If sum of digits in a number is… Read More
Write a function which takes an array and prints the majority element (if it exists), otherwise prints “No Majority Element”. A majority element in an… Read More
Given a pointer to a node to be deleted, delete the node. Note that we don’t have pointer to head node. Recommended: Please solve it… Read More
  Given two integers x and n, write a function to compute xn. We may assume that x and n are small and overflow doesn’t… Read More