Python Does Path Exists Leetcode Blind 150