Two hourglasses

You have two small, simple, unmarked hourglasses. One measures four minutes and the other measures seven. Using only these, how can you be sure the nine minutes time is up?

Flip both hourglasses at the same time. When the four-minute hourglass runs out, flip it over immediately. When the seven-minute hourglass runs out, flip it over immediately. The second time the four-minute hourglass runs out, the seven-minute hourglass will continue to run for one more minute, so inverting it immediately will count the last minute. In total, nine minutes will pass.