I am having trouble understanding how to even approach this question

Given:
One friend heads north 20 miles per hour.
Other heads East 50 miles per hour.
let r be the number of hours traveled.
After t hours the distance traveled by the first friend is
[tex]\text{Distance 1=speed}\times time[/tex]Substitute speed=20 and time =t, we get
[tex]\text{Distance1=20t}[/tex]After t hours the distance traveled by the second friend is
[tex]\text{Distance 2 =speed}\times time[/tex]Substitute speed=50 and time =t, we get
[tex]\text{Distance 2 =}50t[/tex]Using the Pythagoras theorem to find the distance between two friends.
Distance between two friends is
[tex]\text{distance }^2=(20t)^2+(50t)^2[/tex][tex]\text{distance }^2=20^2t^2+50^2t^2[/tex][tex]\text{distance }^2=400r^2+2500r^2[/tex][tex]\text{distance }^2=2900t^2[/tex]Taking square root on both sides, we get
[tex]\text{distance }=\sqrt[]{2900t^2}[/tex][tex]\text{distance }=10\sqrt[]{29}t[/tex]Hence the required distance is
[tex]\text{distance }=10\sqrt[]{29}.t[/tex]