odd_easy = ['R', 'U', 'D']
even_easy = ['L', 'U', 'D', nil]

S = gets.chomp.split('')

odd = S.each_slice(2).map { |s| s.first }
even = S.each_slice(2).map { |s| s.last if s.size >= 2 }

odd = odd.reject { |s| odd_easy.include?(s) }
even = even.reject { |s| even_easy.include?(s) }

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