I recently attended Microsoft Interview for Software Engineer role in Bing Team. Round 1:Hey geek! It's time to become a success story instead of reading… Read More

getchar_unlocked() is similar to getchar() with the exception that it is not thread safe. Below is an example code. // A simple C program to… Read More

The amount which is lent / deposited is called Principal The money that the principal generates is called Interest. This is the money generated as… Read More

The amount which is lent / deposited is called Principal The money that the principal generates is called Interest. This is the money generated as… Read More

Profit and Loss is a topic that is definitely asked in every placement exam. While the questions are not too tricky, some require deeper understanding… Read More

Given a linked list handling string data, check to see whether data is palindrome or not? For example, Input : a -> bc -> d… Read More

Given singly linked list with every node having an additional “arbitrary” pointer that currently points to NULL. We need to make the “arbitrary” pointer to… Read More

Given an ancestor matrix mat[n][n] where Ancestor matrix is defined as below. mat[i][j] = 1 if i is ancestor of j mat[i][j] = 0, otherwise… Read More

Number is represented in linked list such that each digit corresponds to a node in linked list. Add 1 to it. For example 1999 is… Read More

There were 6 rounds in total. 1) Online coding – hackerearth Three Questions in 1.15hr. Total 50 marks. Questions were in increasing order of the… Read More

Given two strings, find the length of the longest subsequence present in both of them. Examples: Attention reader! Don’t stop learning now. Get hold of all… Read More

Given an array of integers, and a number ‘sum’, find the number of pairs of integers in the array whose sum is equal to ‘sum’.… Read More

Given a Binary Tree where all values are from 0 to n-1. Construct an ancestor matrix mat[n][n]. Ancestor matrix is defined as below. mat[i][j] =… Read More

Given a linked list, rearrange it such that the converted list should be of the form a < b > c < d > e… Read More

Given two arrays that are duplicates of each other except one element, that is one element from one of the array is missing, we need… Read More