def f():
    s = input()
    for i in range(len(s)):
        if i%2 == 1:
            if s[i] == "L" or s[i] == "U" or s[i] == "D":
                continue
            else:
                return "No"
        else:
            if s[i] == "R" or s[i] == "U" or s[i] == "D":
                continue
            else:
                return "No"
    return "Yes"
print(f()) def f():
    s = input()
    for i in range(len(s)):
        if i%2 == 1:
            if s[i] == "L" or s[i] == "U" or s[i] == "D":
                continue
            else:
                return "No"
        else:
            if s[i] == "R" or s[i] == "U" or s[i] == "D":
                continue
            else:
                return "No"
    return "Yes" f s = input() s input() input for i in range(len(s)):
        if i%2 == 1:
            if s[i] == "L" or s[i] == "U" or s[i] == "D":
                continue
            else:
                return "No"
        else:
            if s[i] == "R" or s[i] == "U" or s[i] == "D":
                continue
            else:
                return "No"
     i range(len(s)) range len(s) len s if i%2 == 1:
            if s[i] == "L" or s[i] == "U" or s[i] == "D":
                continue
            else:
                return "No"
        else:
            if s[i] == "R" or s[i] == "U" or s[i] == "D":
                continue
            else:
                return "No"
     i%2 == 1 i%2 i 2 1 if s[i] == "L" or s[i] == "U" or s[i] == "D":
                continue
            else:
                return "No"
         s[i] == "L" or s[i] == "U" or s[i] == "D" s[i] == "L" or s[i] == "U" s[i] == "L" s[i] s i "L" s[i] == "U" s[i] s i "U" s[i] == "D" s[i] s i "D" continue return "No" "No" if s[i] == "R" or s[i] == "U" or s[i] == "D":
                continue
            else:
                return "No"
     s[i] == "R" or s[i] == "U" or s[i] == "D" s[i] == "R" or s[i] == "U" s[i] == "R" s[i] s i "R" s[i] == "U" s[i] s i "U" s[i] == "D" s[i] s i "D" continue return "No" "No" return "Yes" "Yes" print(f()) print f() f def f():
    s = input()
    for i in range(len(s)):
        if i%2 == 1:
            if s[i] == "L" or s[i] == "U" or s[i] == "D":
                continue
            else:
                return "No"
        else:
            if s[i] == "R" or s[i] == "U" or s[i] == "D":
                continue
            else:
                return "No"
    return "Yes" def f():
    s = input()
    for i in range(len(s)):
        if i%2 == 1:
            if s[i] == "L" or s[i] == "U" or s[i] == "D":
                continue
            else:
                return "No"
        else:
            if s[i] == "R" or s[i] == "U" or s[i] == "D":
                continue
            else:
                return "No"
    return "Yes" f
def f():
    s = input()
    for i in range(len(s)):
        if i%2 == 1:
            if s[i] == "L" or s[i] == "U" or s[i] == "D":
                continue
            else:
                return "No"
        else:
            if s[i] == "R" or s[i] == "U" or s[i] == "D":
                continue
            else:
                return "No"
    return "Yes"
print(f())