Third Maximum Element Leetcode Problems Python