object Main extends App {
    val steps = scala.io.StdIn.readLine.zipWithIndex
    val odd = steps.filter(s => (s._2 + 1) % 2 != 0).map(_._1)
    val even = steps.filter(s => (s._2 + 1) % 2 == 0).map(_._1)

    val isEasyOdd = odd.forall(s => Set('R', 'U', 'D').contains(s))
    val isEasyEven = even.forall(s => Set('L', 'U', 'D').contains(s))

    val isEasy = if (isEasyOdd && isEasyEven) "Yes" else "No"
    println(isEasy)
}