a boat sails from port p to port q at a speed of 20 km/h along a straight course. once the boat reaches port q, it sails back to port p along the same course at a speed of 30 km/h. if the total time taken by the boat is 1 hour, find the distance between ports p and q.