s = list(input())

flag = True

for i in range(len(s)):
    if i % 2 == 0:
        if s[i] == "L":
            flag = False
            break
    else:
        if s[i] == "R":
            flag = False
            break

if flag:
    print("Yes")
else:
    print("No")
 s = list(input()) s list(input()) list input() input flag = True flag True for i in range(len(s)):
    if i % 2 == 0:
        if s[i] == "L":
            flag = False
            break
    else:
        if s[i] == "R":
            flag = False
            break i range(len(s)) range len(s) len s if i % 2 == 0:
        if s[i] == "L":
            flag = False
            break
    else:
        if s[i] == "R":
            flag = False
            break i % 2 == 0 i % 2 i 2 0 if s[i] == "L":
            flag = False
            break
     s[i] == "L" s[i] s i "L" flag = False flag False break if s[i] == "R":
            flag = False
            break s[i] == "R" s[i] s i "R" flag = False flag False break if flag:
    print("Yes")
else:
    print("No") flag print("Yes") print "Yes" print("No") print "No" flag = True True flag s = list(input()) list(input()) s flag = False False flag flag = False False flag
s = list(input())

flag = True

for i in range(len(s)):
    if i % 2 == 0:
        if s[i] == "L":
            flag = False
            break
    else:
        if s[i] == "R":
            flag = False
            break

if flag:
    print("Yes")
else:
    print("No")

