Put shortest path in the right spot.