Assume that they start at the origin. After h hours, Tanner will be at point [tex](0, 2.5h)[/tex], while Sheldon will be at point [tex](3h, 0)[/tex]
So, the distance between them is
[tex]\sqrt{(0-3h)^2+(2.5h-0)^2} = \sqrt{9h^2+6.25h^2}=\sqrt{15.25h^2}=h\sqrt{15.25}[/tex]
This distance becomes 4 miles after
[tex]h\sqrt{15.25}=4 \iff h=\dfrac{4}{\sqrt{15.25}}\approx 1.02[/tex]
So, they can walk for a little bit more than 1 hour before they get out of range.