Pipe A can fill a cistern in 60 minutes, while the pipe B can fill it in 40 minutes. They are alternately open for 1 minute. How long will it take the cistern to fill completely?
Let the total time taken be 2x minutes. Both X and Y run for x mins. So $(x/40 + x/60)$ = 1. Solving for x, we get x = 24, which gives 2x = 48.