Posted by: eskay on: November 1, 2008
Both the problems here are based on prisoners and hats….
Question 1:
There are n prisoners in a prison. The prison warden gives them an offer:
Activity:
He will be asking the prisoners to stand in a queue, ordered based on their heights, tallest in the front of the queue and the shortest [...]
Posted by: eskay on: October 26, 2008
I come across loads of interesting questions which have been asked in interviews. Just thought of posting them here in my blog…
Question 1:
There is a long table with 100 cups arranged in a line. The cups are numbered from one to hundred. Initially all cups are closed with lids.
This is what you do:
First, you open [...]
Posted by: eskay on: May 13, 2008
All square numbers have odd number of factors. All other numbers have even number of factors.
To check whether a number is prime, it is sufficient to check its divisibiliy by all prime numbers less than square root of the number.
A number n is a sum of two squares if and only if all prime factors of n [...]