Add #8 Python solution