Shortest Path Leetcode Graph Problem