strs = gets.split("").map(&:chomp)

odd = []
even = []
index = 1

strs.each do |str|
    if index%2 == 0
        even.push(str)
    else
        odd.push(str)
    end
    index += 1
end

odd.delete('R')
odd.delete('U')
odd.delete('D')

even.delete('L')
even.delete('U')
even.delete('D')

if odd.empty? && even.empty?
    puts 'Yes'
else
    puts 'No'    
end
