{"raw_statement":[{"iden":"problem statement","content":"Takahashi is practicing _shiritori_ alone again today.\nShiritori is a game as follows:\n\n*   In the first turn, a player announces any one word.\n*   In the subsequent turns, a player announces a word that satisfies the following conditions:\n    *   That word is not announced before.\n    *   The first character of that word is the same as the last character of the last word announced.\n\nIn this game, he is practicing to announce as many words as possible in ten seconds.\nYou are given the number of words Takahashi announced, $N$, and the $i$\\-th word he announced, $W_i$, for each $i$. Determine if the rules of shiritori was observed, that is, every word announced by him satisfied the conditions."},{"iden":"constraints","content":"*   $N$ is an integer satisfying $2 \\leq N \\leq 100$.\n*   $W_i$ is a string of length between $1$ and $10$ (inclusive) consisting of lowercase English letters."},{"iden":"input","content":"Input is given from Standard Input in the following format:\n\n$N$\n$W_1$\n$W_2$\n$:$\n$W_N$"},{"iden":"sample input 1","content":"4\nhoge\nenglish\nhoge\nenigma"},{"iden":"sample output 1","content":"No\n\nAs `hoge` is announced multiple times, the rules of shiritori was not observed."},{"iden":"sample input 2","content":"9\nbasic\nc\ncpp\nphp\npython\nnadesico\nocaml\nlua\nassembly"},{"iden":"sample output 2","content":"Yes"},{"iden":"sample input 3","content":"8\na\naa\naaa\naaaa\naaaaa\naaaaaa\naaa\naaaaaaa"},{"iden":"sample output 3","content":"No"},{"iden":"sample input 4","content":"3\nabc\narc\nagc"},{"iden":"sample output 4","content":"No"}],"translated_statement":null,"sample_group":[],"show_order":["default"],"formal_statement":null,"simple_statement":null,"has_page_source":true}