Leetcode Simple Python Program For Ranked