The Wayback Machine - https://web.archive.org/web/20240204103502/https://www.geeksforgeeks.org/puzzle-27-hourglasses-puzzle/
Open In App
Related Articles

Puzzle 27 | (Hourglasses Puzzle)

Improve
Improve
Improve
Like Article
Like
Save Article
Save
Report issue
Report

Puzzle: Given two hourglass of 4 minutes and 7 minutes, the task is to measure 9 minutes.

Solution:

  1. At 0 minutes: Start both hourglasses at the same time.
  2. At 4 minutes: 4 minutes hourglass runs out and flip it. 7 minutes hourglass is left with 3 minutes.
  3. At 7 minutes: 4 minutes hourglass is left with 1 minute. 7 minutes hourglass runs out and flip it.
  4. At 8 minutes: 4 minutes hourglass runs out and 7 is filled with 6 minutes and 1 minute on the other side. Flip it as the sand is left with 1 minute.
  5. At 9 minutes: 7 minutes hourglass becomes empty from above side.

Hence we measured 9 minutes.

Whether you're preparing for your first job interview or aiming to upskill in this ever-evolving tech landscape, GeeksforGeeks Courses are your key to success. We provide top-quality content at affordable prices, all geared towards accelerating your growth in a time-bound manner. Join the millions we've already empowered, and we're here to do the same for you. Don't miss out - check it out now!

Looking for a place to share your ideas, learn, and connect? Our Community portal is just the spot! Come join us and see what all the buzz is about!


Last Updated : 19 Jan, 2023
Like Article
Save Article
Previous
Next
Share your thoughts in the comments
Similar Reads