Brain Teasers & Puzzles
-
- 1,283.9K views
- 1 answers
- 0 votes
-
The Little ant seems to be always confused.
You know why ?View SolutionSubmit Solution- 1,284.7K views
- 1 answers
- 0 votes
-
When does an American/Indian Potato changes its nationality ?
View SolutionSubmit Solution- 1,285.5K views
- 1 answers
- 0 votes
-
- 1,288.3K views
- 2 answers
- 0 votes
-
- 1,434.0K views
- 1 answers
- 0 votes
-
Consider a game that you play against an opponent. In front of you are an even number of coins of possibly different denominations. The coins are arranged in a line. You and your opponent take turns selecting coins. Each player takes one coin per turn and must take it from an end of the line, that is, the current leftmost coin or the current rightmost coin. When all coins have been removed, add the value of the coins collected by each player. It is possible that you and your opponent end up with the same value (for example, if all coins have the same denomination). Develop a strategy where you take the first turn and where your final value is at least that of your opponent (that is, don’t let your opponent end up with coins worth more than your coins).
Submit Solution- 1,430.1K views
- 0 answers
- 0 votes
-
A spy is located on a one-dimensional line. At time 0, the spy is at location A. With each time interval, the spy moves B units to the right (if B is negative, the spy is moving left). A and B are fixed integers, but they are unknown to you. You are to catch the spy. The means by which you can attempt to do that is: at each time interval (starting at time 0), you can choose a location on the line and ask whether or not the spy is currently at that location. That is, you will ask a question like “Is the spy currently at location 27?” and you will get a yes/no answer. Devise an algorithm that will eventually find the spy.
Submit Solution- 1,430.4K views
- 0 answers
- 0 votes
-
Consider the following array operations. Init(N,d) initializes an array of N elements so that each element has value d. Once Init has been called, the following two operations can be applied: For any i such that 0 <= i < N, Get(i) returns the array element at position i and Set(i,v) sets the array element at position i to the value v.
Given any amount of memory you want, implement the three operations so that each operation has an O(1) time complexity.
Submit Solution- 1,430.0K views
- 0 answers
- 0 votes
-
100 prisoners agree on a strategy before playing the following game: One at a time (in some unspecified order), each of the prisoners is taken to a courtyard where there is a line of 100 boxes. The prisoner gets to make choices to open 50 of the boxes. When a box is opened, it reveals the name of a prisoner (the prisoners have distinct names). The names written in the boxes are in 1-to-1 correspondence with the prisoners; that is, each name is found in exactly one box. If after opening 50 boxes, the prisoner has not found his own name, the game is over and all the prisoners lose. But if the prisoner does find the box that contains his name among the 50 boxes he opens, then the prisoner is taken to the other side of the courtyard where he cannot communicate with the others, the boxes are once again closed, and the next prisoner is brought out into the courtyard. If all prisoners make it to the other side of the courtyard, they win.
One possible strategy is for each prisoner to randomly select 50 boxes and open them. This gives the prisoners 1 chance out of 2100 to win–a slim chance, indeed. But the prisoners can do better, using a strategy that for a random configuration of the boxes will give them a larger chance of winning. How good a strategy can you develop?
Submit Solution- 1,429.9K views
- 0 answers
- 0 votes
More puzzles to try-
Playing card riddle
There is a deck of 100 initially blank cards. The dealer is allowed to write ANY positive integer, one per ...Read More »Eat Drink or Burn the gift riddle
A person gives gift to his wife saying, eat it if you are hungry, drink if you are thirsty and ...Read More »How did the grand children know it?
A man was telling some of his war stories to his grandchildren. “When the World War I was on the ...Read More »How do you get out alive?
Imagine you are swimming in the ocean and a bunch of hungry sharks surround you. How do you get out ...Read More »Word Ladder
Complete the word ladder in 7 moves by removing one letter in each rung.Read More »City without People
What City has No People? A) Velocity B) Electricity C) Elasticity D) All the aboveRead More »Car Driving
Jenifer is learning to drive her car. She went down a one way lane and in the wrong direction. But ...Read More »King and wise jeweler’s Gold rings puzzle
A king asks a learned man to visit his palace, to which the learned man responds: “I will come some ...Read More »What is the cost of bat and ball?
Cricket bat and ball cost $50. If the bat cost $49 more than the ball, what is the cost of ...Read More »Kris Cross
Can you place six X (crosses) in below board without making three in a row in any way ?Read More »Identify Me Riddle
Identify Me Hint1: I am a god Hint 2: I am a planet Hint 3: measurer of heatRead More »You are in space riddle
Imagine you are in space. How do you get down on the Earth?Read More »Smart Clock
Divide the clock’s face into three equal parts exactly with two lines. Therefore the sum of the numbers in the ...Read More »Car with missing wheel riddle
You Are in A Car, of which one wheel is missing. But Suddenly, There is a killer coming from your ...Read More »Find the next in series
Find the last number in the series below: voN luJ yaM raM —Read More »Complete the pairs
Write the missing half of each word pair ? 1. Peace and 2. Thunder and 3. Back and 4. Thick ...Read More »World is Gray
Without it all the world is gray and dull for everyone. It reflects rays of sun, and yet it does ...Read More »I leave you with mixed feelings
Sometimes, I leave you with “mixed” feelings. More times than not, I teach you a lesson. I give what I ...Read More »Crime Investigation Riddle
Five men, whose names are Bob Edison, Tom Stevenson, Marty Brown, Jim Davis, and John Alberts were being questioned by ...Read More »Eyes behind
The strangest creature you will ever find – Two eyes in front and many more behind.Read More »