main :: IO ()
main = do
    s <- getLine
    putStrLn $ if good s then "Yes" else "No"
    where
        good "" = True
        good ('L':_) = False
        good (_:[]) = True
        good (_:'R':_) = False
        good (_:_:xs) = good xs
