main :: IO()
main = do
    n <- getLine
    let list = scan n {-←getLineの繰り返しの関数にしたい-}
    loop n list
    if loop == False then "No" else "Yes"
    {-↑しりとりかどうかまだ試してないからそこも後で書こうね-}

    scan :: IO [Char] -> a -> [Char]
    scan list n
    scan w <- getLine{-ここで怒られてるけどわからない・・・；；-}
    scan w ++ (scan list n-1)

    loop :: [a] -> Bool
    loop (x:xs) = elemm x xs

    elemm :: (Eq a) => a -> [a] -> Bool
    elemm a [] = False
    elemm a (x:xs)
        | ( x == a ) = True
        | otherwise = a 'elemm' xs