SSSP that collects path and distance