Puzzle #111: Soldiers in a Line

This is another beautiful puzzle that I got through my daughter (Anisha) and her friend (Abhiram), which they got in Alok Mittal’s Mathematical Circles class.

In a line up of 10 soldiers, what is the least number of soldiers that can be picked in order of either ascending or descending heights? Assume that no two soldiers have the same height. Soldiers can be picked from anywhere in the line, but their order of standing cannot be changed.

Please send your answers either directly on the blog site as comments, or to me at alokgoyal_2001@yahoo.com. If you like the puzzle, please share it with others. If you have interesting puzzles to share, please send them to me at my e-mail given above.

Happy Sunday!

Posted in Puzzles | Tagged , | Leave a comment

Solution to Puzzle #109: Fox in a Hole

From this week, I am moving to a one-week shifted model, where I will publish the solution for puzzles posted 2 week back instead of one week back, this will give everyone two weeks to look at the puzzle just in case they do not get a chance in the first week.

For #109, I got a lot of solutions and mostly all correct. It is a very nice puzzle. Folks who sent the correct answer included Pratik Poddar (first one to send a solution, and his solution is the one I am reproducing here – thanks Pratik!), Amit Mittal, Suman Saraf and Siddharth Mulherkar. Tarun Walia sent a correct answer but not an optimal one.

Here is the solution from Pratik, which also has a solution to the generalised version.

Lets prove that 2,3,4,2,3,4 is sufficient and will always give us a solution. (Please note that 4,3,2,4,3,2 will also work)

Initially, the fox could be in either {1,3,5} or {2,4}

If initially the fox was in {2,4} we can prove that the operation 2,3,4 always finds the fox.
(Proof: If 2 did not work, the fox was in 4. So, it would have moved to 3 or 5. If 3 did not work in the second chance, it was at 5. So, it will now move to 4 and will get caught in the third catch)

Now for the case when it begins a place in {1,3,5}. After 3 days, it would go to one in {2,4} and so now a 2,3,4 operation will find the fox.

Related problem: Lets say that the number of holes is not 5 – its n.

Generalising the answer for n holes:

sequence of inspection should be,
Part 1: 2,3,4…,(n-1);
followed by
Part 2: (n-1),(n-2),…2.

if fox started in an even numbered hole, then fox will be found in part 1.
otherwise
if fox started in odd numbered
hole , then fox will be found in part 2.

Proof: The end holes 1 and n are not checked because, before being caught in these end holes, fox will be found in hole 2 or hole n-1. in both parts we are traversing from one end to other and parity of our movement is different in part 1 and part 2. Hence fox will be caught in whichever part our parity matches with that of fox.

So, for the 5 hole case 2,3,4,4,3,2 is also a solution.

Hope you all enjoyed the puzzle!

Posted in Solution | Tagged , | Leave a comment

Puzzle #110: Circular Dining Table

I am leaving for a vacation, and hence not able to post the solution to the last week’s puzzle. In the meantime, here is another puzzle, will post the answers to both next week. This puzzle is courtesy Alok Mittal, who gave this to his students in the Mathematical Circles class.

People are seated around a circular table at a restaurant. The food is placed on a circular platform in the center of the table and this circular platform can rotate. Each person ordered a different entrée, and it turns out that no one has the correct entrée in front of him. Show that it is possible to rotate the platform so that at least two people will have the correct entrée.

Please send your answers either directly on the blog site as comments, or to me at alokgoyal_2001@yahoo.com. If you like the puzzle, please share it with others. If you have interesting puzzles to share, please send them to me at my e-mail given above.

Happy dining…with the right dish!

Posted in Puzzles | Tagged , | 2 Comments

Puzzle #109: Fox in a Hole

A beautiful logic puzzle that I found on Gurmeet’s puzzle collection, which he has attributed originally to K Rustan M Leino at Microsoft Research.

Consider five holes in a line. One of them is occupied by a fox. Each night, the fox moves to a neighboring hole, either to the left or to the right. Each morning, you get to inspect a hole of your choice. What strategy would ensure that the fox is eventually caught?

Please send your answers either directly on the blog site as comments, or to me at alokgoyal_2001@yahoo.com. If you like the puzzle, please share it with others. If you have interesting puzzles to share, please send them to me at my e-mail given above.

Happy hide and seek with the fox!

Posted in Puzzles | Tagged , | 4 Comments

Solution to Puzzle #108: The Double Square Number Problem

Apologies that I could not post the answer last weekend as I was traveling. I was overwhelmed by the number of answers i received for this puzzle – most of them correct. However, many people used spreadsheets or a small software script to figure out the number. Some people used trial and error to derive the answer. Only a few people found the answer with a method – Karan Sharma, my nephew, Pratik Poddar and someone who is posting by the name “Bill Gates” from India – great job! Other people to solve included Sabeer Bhatia, Aman Singla, Adithya Herur, Akshay Joshi, Suman Saraf. If I have missed someone out, my apologies!

The answer is 8833

A simple way to think about it is as follows:

Let x and y be the two parts of the number. Therefore:

x^2 + y^2 = 100*x + y, which can be rearranged as:

y * (y-1) = x * (100-x)

We know that 1233 is a solution, which means that the solution works for y = 33. In the equation above you will notice that if the solution works for x (which in this case is 12), it will also work for 100-x, therefore 8833 has to be a solution.

Pratik gave a more elaborate answer, reproducing it here:

Let the number be of the form “ab” = 100*a + b where a and b are >0 and <100 and represented as two digit numbers like 07 or 95

100*a + b = a^2 + b^2
a*(100-a) = b*(b-1)

One of b and b-1 is even
So, At least one of a and 100-a have to be even
So, a is even

Lets say a = 2*x

4*x*(50-x) = b*(b-1)

Max value of LHS is 2500
So, Max value of b is 50

One of b and b-1 is odd. So, whatever is even, is of the form 4*y

Case 1: b = 4*y and y<13 and a = 2*x and x Will explore later
If x is even, y is a multiple of 4 or one of 4,8,12 => No solution

Case 2: b-1 = 4*y and y<13 and a = 2*x and x Will explore later
If x is even, y is a multiple of 4 or one of 4,8,12 => y=8,x=44,6 is a solution

We have a solution.
b=33
a = 12 or 88

so 8833 and 1233 are valid numbers

Finally, Adithya Herur gave an interesting twist, which is that what if x and y ( or a and b) are 3 digits or 4 digits each. Here are answers for these, not sure though if these are the only solutions:

for an N with 6 digits : 990100
for an N with 8 digits : 94122353

Thanks to Karan, “Bill Gates”, Pratik and Adithya!

Hope you all enjoyed the puzzle!

Posted in Solution | Tagged , | Leave a comment

Puzzle #108: The Double Square Number Problem

While browsing through mind cipher.com, I came across this wonderful puzzle…a good puzzle for those who love to play with numbers.

It’s said that a number N with 4 digits is a double-square number when it equals the sum of the squares of two numbers: one formed by the first two digits of N, in the order they appear in N and the other formed by the two last digits of N in the order they appear in N.

For example, 1233 is a double-square number since 1233 = 12^2 + 33^2. Find another double-square number.

Please send your answers either directly on the blog site as comments, or to me at alokgoyal_2001@yahoo.com. If you like the puzzle, please share it with others. If you have interesting puzzles to share, please send them to me at my e-mail given above.

Happy number crunching!

Posted in Puzzles | Tagged , | 3 Comments

Solution To Puzzle #107: The Longest Path

I was surprised to see relatively fewer answers for this puzzle. I received two partially correct answer and one fully correct answer. Anisha, my 11 year old, correctly pointed out the maximum length, and so did Mayank Aggarwal from California. Only Suman Saraf gave a proof of the maximum path – well done all!

Here is the answer – You can have a maximum length of 34. A brief logic is as follows, though the video does a better job of explaining this:

– Color the intersections as black and white so that no two adjacent intersections are of the same color (like a chess board, where the intersections are the squares) – you have a 6×6

– Since there are 36 intersections, and A & B are part of the path, there can be a maximum path of 35

– However, since A and B will always be the same color (either black and white), one needs an even number of steps to go from A to B

– Therefore maximum path length can be 34

Attaching the answer in the following video:

Hope you all enjoyed the puzzle!

 

Posted in Solution | Tagged , , | Leave a comment

Puzzle #107: The Longest Path

I read this beautiful puzzle in the book “Invitation to a Mathematical Festival” by Ivan Yashchenko.

Take a look at the figure below. A tourist wants to walk along the streets of Old Town from the train station (A) to his hotel (B). He wants the route to be as long as possible, but without visiting the same intersection twice, since he finds it boring. Draw the longest such route on the map, and prove that nothing longer is possible.

Puzzle #107

Puzzle #107

 

Please send your answers either directly on the blog site as comments, or to me at alokgoyal_2001@yahoo.com. If you like the puzzle, please share it with others. If you have interesting puzzles to share, please send them to me at my e-mail given above.

Happy visiting the Old Town!

Posted in Puzzles | Tagged , , | Leave a comment

Solution to Puzzle #106: Cards and Two Magicians

A delightful puzzle – thanks again to Pallav Pandey! Also for a change, I had a chance to work on a puzzle myself as someone else contributed. I loved solving the puzzle along with my 11 year old daughter Anisha. I got answers from three other people, who all gave partially correct answers – Prateek Poddar, Suman Saraf and Karan Sharma – all very smart and regular folks providing answers.

I am attaching a link to the video which gives the solution for children.

For others, here is a potential way to do this, and would request Pallav to send me the answer that he knows.

Since there are 5 cards and 4 colors/ suits, there will be at least one color for which we have two or more cards. M1 can give back a card of that color to the audience and keep the other one as the first card in the sequence to communicate the color to M2. That was easy and everyone got that.

Notice that these are rectangular cards, and therefore can be placed in two orientation – vertical and horizontal. We can use these two possibilities to denote a “1” or a “0” and therefore use the binary number method to communicate the value of the card using the 4 cards we have (including the first one that communicates the color).

Hope you all enjoyed the puzzle!

 

Posted in Solution | Tagged , , | Leave a comment

Puzzle #106: Cards and Two Magicians

This is a very interesting puzzle contributed by Pallav Pandey – thanks Pallav! I have not solved it yet, and looking forward to working on it!

Magician M1, calls an audience on stage who pulls random 5 cards from the deck.

M1 gives one card back to the guy from the audience; and lays out other 4 cards face-up and side-by-side on the table.

The Magician M2 comes and looks at the 4 open cards and is able to name the 5th card.

How ?

Please send your answers either directly on the blog site as comments, or to me at alokgoyal_2001@yahoo.com. If you like the puzzle, please share it with others. If you have interesting puzzles to share, please send them to me at my e-mail given above.

Enjoy!

Posted in Puzzles | Tagged , , | 4 Comments