we have the following:
John's rate = x mph
William's rate = x -20 mph
[tex]\begin{gathered} v=\frac{d}{t} \\ d=d\cdot t \\ d=x+x-20=2x-20 \\ t=4 \end{gathered}[/tex]d = d, therefore:
[tex]\begin{gathered} 4\cdot(2x-20)=240 \\ 8x-80=240 \\ 8x=240+80 \\ x=\frac{320}{8} \\ x=40 \end{gathered}[/tex]John's rate = 40 mph
Willams's rate = 40 - 20 = 20 mph