To solve this problem, we know that time it takes the person to travel at distance is given by t = distance / rate .So in the attached file, you can see the step by step solution for this problem.
And the answer for this question is: The person should walk 6 - 1.5 miles or 4.5 miles along the shore