{"raw_statement":[{"iden":"problem statement","content":"Takahashi lives in another world. There are slimes (creatures) of $10000$ colors in this world. Let us call these colors Color $1, 2, ..., 10000$.\nTakahashi has $N$ slimes, and they are standing in a row from left to right. The color of the $i$\\-th slime from the left is $a_i$. If two slimes of the same color are adjacent, they will start to combine themselves. Because Takahashi likes smaller slimes, he has decided to change the colors of some of the slimes with his magic.\nTakahashi can change the color of one slime to any of the $10000$ colors by one spell. How many spells are required so that no slimes will start to combine themselves?"},{"iden":"constraints","content":"*   $2 \\leq N \\leq 100$\n*   $1 \\leq a_i \\leq N$\n*   All values in input are integers."},{"iden":"input","content":"Input is given from Standard Input in the following format:\n\n$N$\n$a_1$ $a_2$ $...$ $a_N$"},{"iden":"sample input 1","content":"5\n1 1 2 2 2"},{"iden":"sample output 1","content":"2\n\nFor example, if we change the color of the second slime from the left to $4$, and the color of the fourth slime to $5$, the colors of the slimes will be $1, 4, 2, 5, 2$, which satisfy the condition."},{"iden":"sample input 2","content":"3\n1 2 1"},{"iden":"sample output 2","content":"0\n\nAlthough the colors of the first and third slimes are the same, they are not adjacent, so no spell is required."},{"iden":"sample input 3","content":"5\n1 1 1 1 1"},{"iden":"sample output 3","content":"2\n\nFor example, if we change the colors of the second and fourth slimes from the left to $2$, the colors of the slimes will be $1, 2, 1, 2, 1$, which satisfy the condition."},{"iden":"sample input 4","content":"14\n1 2 2 3 3 3 4 4 4 4 1 2 3 4"},{"iden":"sample output 4","content":"4"}],"translated_statement":null,"sample_group":[],"show_order":["default"],"formal_statement":null,"simple_statement":null,"has_page_source":true}