move = ["상", "상", "우", "하"] answer = 2 for i in range(1,len(move)): if move[i] != move[i-1]: answer += 10 answer += 2 else: answer += 2 print(answer)
To embed this project on your website, copy the following code and paste it into your website's HTML: