Amazon Leetcode Problems Python