Leetcode 856 Python Count Items In A List