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

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

    rupu :: [a] -> Bool
    rupu (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