Let the certain distance be d and time t.
Now, by given condition,
d/3 = ( t + 15 ) min ( t +15 )/60 h
⇒ 20d = t + 15
⇒ t = 20d - 15 ......(i)
And from another condition,
d/4 = (t - 15) min = ( t - 15 )/60 h
⇒ 15d = t - 15
⇒ t = 15d + 15 ...(ii)
From Eqs. (i) and (ii), we get
20d - 15 = 15d + 15
⇒ 5d = 30
∴ d = 6 km.