let's say X is the walking time, then 1-X is the running time
distance = time multiply by speed
walking distance: 3X
running distance: 5(1-X)
and they are the same: 3x=5(1-X)
3x=5-5x
8x=5
x=5/8 (hour)
Distance; 5/8 times 3=15/8
total distance: 30/8=3 6/8=3 3/4=3.75mi