## The painter’s partition problem | Set 2

We have to paint n boards of length {A1, A2, .. An}. There are k painters available and each takes 1 unit time to paint… Read More »

We have to paint n boards of length {A1, A2, .. An}. There are k painters available and each takes 1 unit time to paint… Read More »

Round 1: Coding Sample In this coding sample, I was given 90 minutes to answer 2 coding questions. Question 1: Given a string A consisting… Read More »

We have to paint n boards of length {A1, A2…An}. There are k painters available and each takes 1 unit time to paint 1 unit… Read More »

Given an array of length n + 1, containing elements 1 through n and a space, Requires the use of a given swap (index i,… Read More »

It was a nice experience to be part of google placement programme. There were 4 Rounds The online test consists of 4 modules. For each… Read More »

The Google Foo bar challenge has been known for the last 5 years or more as a secret process of hiring developers and programmers all… Read More »

Given two sequences A, B, find out number of unique ways in sequence A, to form a subsequence of A that is identical to the… 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 »

Given a string, the task is to return the length of its longest possible chunked palindrome. It means a palindrome formed by substring in the… Read More »

Given a paper of size A x B. Task is to cut the paper into squares of any size. Find the minimum number of squares… Read More »

Given a Binary Search Tree, find median of it. If no. of nodes are even: then median = ((n/2th node + (n+1)/2th node) /2 If… Read More »

Given an integer array of n integers, find sum of bit differences in all pairs that can be formed from array elements. Bit difference of… Read More »

There are n-pairs and therefore 2n people. everyone has one unique number ranging from 1 to 2n. All these 2n persons are arranged in random… Read More »

The solution will be evaluated on following parameters. Object Oriented Design aspects of the solution. Overall coding practices.

Given a string you need to print longest possible substring that has exactly M unique characters. If there are more than one substring of longest… Read More »