# 問題：https://atcoder.jp/contests/abc141/tasks/abc141_b

s = input()
i = 1
res = True
for ch in s:
    if i % 2 == 1 and ch == 'L':
        res = False
        break
    elif i % 2 == 0 and ch == 'R':
        res = False
        break
    i += 1

if res:
    print('Yes')
else:
    print('No') s = input() s input() input i = 1 i 1 res = True res True for ch in s:
    if i % 2 == 1 and ch == 'L':
        res = False
        break
    elif i % 2 == 0 and ch == 'R':
        res = False
        break
    i += 1 ch s if i % 2 == 1 and ch == 'L':
        res = False
        break
    elif i % 2 == 0 and ch == 'R':
        res = False
        break
     i % 2 == 1 and ch == 'L' i % 2 == 1 i % 2 i 2 1 ch == 'L' ch 'L' res = False res False break elif i % 2 == 0 and ch == 'R':
        res = False
        break
     i % 2 == 0 and ch == 'R' i % 2 == 0 i % 2 i 2 0 ch == 'R' ch 'R' res = False res False break i += 1 i 1 if res:
    print('Yes')
else:
    print('No') res print('Yes') print 'Yes' print('No') print 'No' i = 1 1 i res = False False res res = True True res i += 1 1 i s = input() input() s res = False False res
# 問題：https://atcoder.jp/contests/abc141/tasks/abc141_b

s = input()
i = 1
res = True
for ch in s:
    if i % 2 == 1 and ch == 'L':
        res = False
        break
    elif i % 2 == 0 and ch == 'R':
        res = False
        break
    i += 1

if res:
    print('Yes')
else:
    print('No')
