##
K-th Element of Two Sorted Arrays
May 21, 2017

Given two sorted arrays of size m and n respectively, you are tasked with finding the element that would be at the k’th position of… Read More »

May 21, 2017

Given two sorted arrays of size m and n respectively, you are tasked with finding the element that would be at the k’th position of… Read More »

May 17, 2017

Given many stacks of coins which are arranged adjacently. We need to collect all these coins in the minimum number of steps where in one… Read More »

May 14, 2017

An element is a peak element if it is greater than or equal to its four neighbors, left, right, top and bottom. For example neighbors… Read More »

Given a sorted matrix mat[n][m] and an element ‘x’. Find position of x in the matrix if it is present, else print -1. Matrix is… Read More »

April 19, 2017

Given a set of points, a Convex hull is the smallest convex polygon containing all the given points. Input is an array of points specified… Read More »

April 18, 2017

Given an array representing n positions along a straight line. Find k (where k

March 17, 2017

Given number of pages in n different books and m students. The books are arranged in ascending order of number of pages. Every student is… Read More »

March 3, 2017

Strassen’s matrix is a Divide and Conquer method that helps us to multiply two matrices(of size n X n). You can refer to the link,… Read More »

March 1, 2017

Consider an array of distinct numbers sorted in increasing order. The array has been rotated (anti-clockwise) k number of times. Given such an array, find… Read More »

December 26, 2016

Given a matrix of N rows and M columns, the task is to find the minimum absolute difference between any of the two adjacent elements… Read More »

December 18, 2016

You are given a bitonic sequence, the task is to find Bitonic Point in it. A Bitonic Sequence is a sequence of numbers which is… Read More »

December 14, 2016

Given a sorted array of n elements containing elements in range from 1 to n-1 i.e. one element occurs twice, the task is to find… Read More »

August 12, 2016

Given a sorted array and a value x, the floor of x is the largest element in array smaller than or equal to x. Write… Read More »

July 3, 2016

Given a number n, find the cube root of n. Examples: Input: n = 3 Output: Cubic Root is 1.442250 Input: n = 8 Output:… Read More »

June 29, 2016

Given an sorted array of positive integers, count number of occurrences for each element in the array. Assume all elements in the array are less… Read More »