One pipe can fill a pool in 6 hours, and a second pipe can fill the same pool in 12 hours. If both pipes work together, how long will it take to fill the pool?