Two hikers take two different straight-line paths from the campground. Hiker A walks 4 km and hiker B walks 5 km. If they angle between their paths is 40°, how far apart are the hikers?

c^2 = a^2 + b^2 - 2 a c cos C

c^2 = 16 + 25 - 40 cos 40