# Logic Puzzles

Customize layout

This is a collection of some of the nice Logic Puzzles that I have come across and I recollect. Some that I found particularly hard are mentioned at the end under the Hard Difficulty section.

Easy / Medium Difficulty
1. You are given 10 bags of gold coins each containing 10 coins each. Also, it is given that each of the 9 bags contains coins of weight 1g each, and the 10th bag contains coins of weight 1.01g each. Also, an infinite number of good coins and a digital relative balance of infinite precision is provided. Using the relative balance only once find out which bag contains the faulty coins!
2. You are given an infinite number of non-uniform ropes(ropes of non-uniform cross sectional area at any place you cut them). Also, it is given that once you start burning a rope, it will finish burning in 60min. However, since the rope is non-uniform, half the rope will not necessarily burn in 30min. Now, how would you measure exactly 30min and 45min using such ropes which are each non-uniform, but not identical. However, they all burn in 60min.
3. Bobby has 100 lockers numbered 0 to 99, and has kept the keys to his bike and car in 2 of them. He, however being a very forgetful person has forgotten which those 2 locker numbers are! He however does remember that when he reversed the digits of the first number, the second number appeared. He also remembers that when he adds the 2 locker numbers he gets a perfect square as the answer. Also, on taking the difference of the 2 locker numbers, he gets a perfect square as the answer. Find the 2 locker numbers.
4. Bobby has kept the keys of his friend's bike and car in 2 other lockers which he had forgotten again! He however, as usual does remember that when he reversed the digits of one of the locker numbers, he got the 2nd one! He also remembers that on taking the sum of the 2 locker numbers, he got a perfrect square, and on taking the difference of the 2 locker numbers, he got a perfect cube as the answer. Find the 2 locker numbers.
5. While leaving the house, Bobby remembers to take the house keys with him. So, he enters the room where he has kept the house keys. There are many rectangular boxes(cuboids) in this room, and Bobby has kept the house keys in one of them, but has forgotten which one! He however does remember that the box was such that when he found the volume of the box in cubic units, it was numerically equal to the sum of the surface area of each side of the box in square units. Also, the dimensions of the cuboid are such that each of them is a Natural number, and each dimension is distinct and a non-prime. Find which box Bobby has placed the keys in!
6. You are given a 4-digit number such that the sum and product of its digits are equal. Also, the number itself is divisible by the sum or product(because they both are equal). The number is not "0000". Find the number.
7. You are given 7-digits. When the first 3 digits taken as a 3-digit number are added to 447, the result is the next 3 digits. When the last 3-digits are added to 447, the result is the first 3-digits. Find the 7-digits.
8. You are given 1023 apples, and 10 crates. Divide the apples such that suppose the customer asks you for any number of apples, you are able to give him/her exactly that many number of apples using an integral number of crates.
9. 2 towns A and B are 20-miles apart along a straight line. 2 motorcyclists are standing at towns A and B facing each other. There is a fly sitting on motorcyclist A's nose. The 2 motorcyclists each ride at the speed of 10mph, and the fly flies at the rate of 15mph. The 2 motorcyclists start off simultaneously from their respective initial points, and simultaneously, the fly sitting on motorcyclist A's node starts flying in the direction of motorcyclist B. When it touches the motorcyclists' nose, it turns and goes back to motorcyclist A. On reaching his node, it turns back again, and continues this routine. How many miles will the fly have covered before it gets crushed between the noses of the 2 motorcyclists?
10. You are given 16 light bulbs arranged in a circle. You are also given a push switch. When ever you push the switch, the state of the bulbs changes according to the constraints: If the state of a bulb and it's clockwise neighbour is the same(both ON or both OFF), then the new state of the bulb will be ON. If however, the state of the bulb and its clockwise neighbor is opposite(one ON and the other OFF or vice-versa), then the new state of the bulb is OFF. Given ANY initial states of the bulbs, the push switch must be pushed at least X number of times so that no matter how many more times you push the switch, the bulbs always remain ON. Find X.
11. A teacher has 3 students and 5 caps. 3 caps are Green in color, and 2 are Red in color. He makes the 3 students A, B and C stand in a straight line such that A is first, followed by B and tailed off by C. Thus, C can see both A and B, but B can see only A, and A can see no one. He tells the 3 students to shut their eyes and places the 3 caps randomly on their heads. He then places the 2 remaining caps in his pocket where no one including himself can see them. Then he asks the students to open their eyes, and asks student C which cap he has on his head. C replies "I can't tell". He then moves on to student B and asks him the same question, which is answered in the same manner by the student as the previous one. He then moves on to the student A, and asks him the same question. However, student A is able to reply, and tells the teacher the color of the cap he has on his head correctly! What color cap did student A have on his head?
12. You are given 4 coins out of which at most 1 is defective(ie. heavier or lighter than the remaining 3). You are also given an infinite number of good(non-defective) coins. Using a relative scale balance at most 2 times, find out whether there is a defective coin, and if there is any such coin, then determine whether it is heavier or lighter than the remaining 3 coins.
13. You are give 16 coins out of which at most 1 is defective Using the relative scale balance at most 4 times, determine whether there is a defective coin, and if there is any such coin, then determine whether it is heavier or lighter than the remaining 15 coins.
14. You are given 9 coins out of which exactly one is defective. Using the relative balance at most 3 times, determine the defective coin.
15. You are give 12 coins out of which exactly one is defective [either heavier or lighter]. Using the relative balance at most 3 times, determine which coin it is and also wheteher it is heavier or lighter compared to the other 11.
16. There are 2 students A and B. They are given 2 numbers n and n+1 (A is given the number n and B the number n+1). However, neither of them knows what number the other has. They only know that the 2 numbers given to them are consecutive. A buzzer sounds every minute. Either student can say when the buzzer sounds whether he/she knows the number that the other student has. Which student will speak first, guessing correctly what number the other has, and after how many beeps?
17. I have a certain number of 10 rupee notes, and a certain number of 1 rupee notes, such that both of these are at least 1 in number. The number of 1 rupee notes multiplied by the number of 10 rupee notes is equal to the total amount of money I possess in rupees. Also, the number of 10 rupee notes is not a prime number. How much money do I possess in rupees?
Hard Difficulty
1. There are 2 numbers x and y such that 2 <= x <= 99 and 2 <= y <= 99. There are 2 persons P and S such that P is given the product xy of the 2 numbers and S is given the sum x+y of the 2 numbers. The following conversation takes place between both of them:
1. P: I don't know the 2 numbers.
2. S: I knew you wouldn't know them.
3. Ok, now I know the 2 numbers.
4. Now I too know the 2 numbers.
Find the 2 numbers, and show that the solution is unique.
2. There was once a man who had 2 daughters A and B. He converted his entire estate into 9 or 16 diamonds, and decided to give each daughter some diamonds. Suppose MAX denotes the maximum number of diamonds, and he gave daughter A X diamonds, then daughter B got MAX-X diamonds. What he did just before dying was to tell daughter A how many diamonds daughter B had, and he also told daughter B how many diamonds daughter A had. After he died, each daughter wanted to know how many diamonds she had gotten, so they had the following conversation:
1. A: Tell me how many diamonds I got.
2. B: No first you tell me how many diamonds I got.
3. Ok, I now how many diamonds I got.
4. I too now know how many diamonds I got.
How many diamonds were there in all, and how many did each of the daughters get?