Shiritori

아직 제출이 없습니다시간 제한2초메모리 제한1024 MB

문제

The original version of Shiritori is played using Japanese hiragana, katakana, or kanji characters. Source WikiMedia

The Japanese game of Shiritori is the perfect game for a long car ride. The rules are simple: the first player picks any word to say, then the second player must choose a new word that begins with the last letter of the word that the first player just said. Your job is to determine if the game was played according to these rules, given a history of the words used in a particular game. In a game, player 11 always starts first.

입력

Input consists of one test case that begins with an integer NN (2N100,0002 \leq N \leq 100\\,000) on a single line.  Each of the following NN lines contains 11 word.  The words are presented in the order in which the players called them out, starting with player 11. All words consist of between 11 and 120120 lowercase English letters.

출력

If the game was played according to the rules, output "Fair Game". Otherwise, find out which player first violated the rules of the game.  That player lost the game, so output "Player <i> lost". For example, if player 11 violated the rules first, output "Player 1 lost".