Question : There are hundred prisoners in a jail. The jailor is benign and decides to give them a chance to be free. Here is what he is going to do: make all the prisoners stand in a row soContinue reading… Hundred prisoners
Author: vamsipavan
An Intellegent Escape
Question : Take this one. You have to ask a single question, whose answer will drive you to the answer of the main question! You have been convicted for some heinous crime. It is your destiny to spend the restContinue reading… An Intellegent Escape
Blue eyed people
Question : A city has a tyrant king. The king hates people with blue eyes. So one fine day, he commands all blue eyed people to commit suicide. The people are so loyal to him that the blue eyed onesContinue reading… Blue eyed people
Paratroopers
Question : Two paratroopers jump from a plane and land on an infinite straight line. They want to find each other. Arrive at an algorithm so that they meet in finite time. You can use only the following type ofContinue reading… Paratroopers
The Rose Garden
Question : You have a rose garden. You have planted 16 rose plants in a circle. Some of them are red and some are white. These plants are somwhat strange. They flower according to the following rules: 1. Each plantContinue reading… The Rose Garden
Thousand poison bottles
Question : There are one thousand bottles of wine. Only one of these bottles is contaminated with a deadly poison. The poison is so potent that even a single drop of contaminated wine can cause death. A scientist wants toContinue reading… Thousand poison bottles
Finding defective coin using old weighing machine …
Question : One of twelve pool balls is a bit lighter or heavier (you do not know) than the others. At least how many times do you have to use an old pair of scales to identify this ball? (aContinue reading… Finding defective coin using old weighing machine …
Twelve Ancestors [clues:trails] — Solution
From general knowledge we know that every person has a male father and a female mother, and is not his or her own ancestor. The twelve include five women and their husbands (1) and two other men (2). None ofContinue reading… Twelve Ancestors [clues:trails] — Solution
Twelve Ancestors [clues:trails]
Try it! (Warning — it will require good intuition about kinship charts and, even with that, seems to be fairly difficult. However it is a pure logic puzzle: besides the explicit Clues, you’ll need only the definitions and most obviousContinue reading… Twelve Ancestors [clues:trails]
Sockets for interprocess communication
This is a simple tutorial on using sockets for interprocess communication. The client server model Most interprocess communication uses the client server model. These terms refer to the two processes which will be communicating with each other. One of theContinue reading… Sockets for interprocess communication