If we let x be the distance from John's Bar to Doug's bar then we can derive the expression,
(x - 10) + x = 40
The value of x from the equation is 25. This means that the distance between John's bar and Dough's bar is 15 km. Since, John's bar and Ben's bar are 60 km apart, the distance between Doug's bar and Ben's bar is 45 km.