def resolve():
    s = input()
    step_odd = 'RUD'
    step_even = 'LUD'
    ans = 'Yes'
    for i,j in enumerate(s):
        if i%2==0 and j not in step_odd:
            ans = 'No'
        elif i%2!=0 and j not in step_even:
            ans = 'No'
        else:
            pass
    print(ans)
resolve() def resolve():
    s = input()
    step_odd = 'RUD'
    step_even = 'LUD'
    ans = 'Yes'
    for i,j in enumerate(s):
        if i%2==0 and j not in step_odd:
            ans = 'No'
        elif i%2!=0 and j not in step_even:
            ans = 'No'
        else:
            pass
    print(ans) resolve s = input() s input() input step_odd = 'RUD' step_odd 'RUD' step_even = 'LUD' step_even 'LUD' ans = 'Yes' ans 'Yes' for i,j in enumerate(s):
        if i%2==0 and j not in step_odd:
            ans = 'No'
        elif i%2!=0 and j not in step_even:
            ans = 'No'
        else:
            pass
     i j enumerate(s) enumerate s if i%2==0 and j not in step_odd:
            ans = 'No'
        elif i%2!=0 and j not in step_even:
            ans = 'No'
        else:
            pass
     i%2==0 and j not in step_odd i%2==0 i%2 i 2 0 j not in step_odd j step_odd ans = 'No' ans 'No' elif i%2!=0 and j not in step_even:
            ans = 'No'
         i%2!=0 and j not in step_even i%2!=0 i%2 i 2 0 j not in step_even j step_even ans = 'No' ans 'No' print(ans) print ans resolve() resolve def resolve():
    s = input()
    step_odd = 'RUD'
    step_even = 'LUD'
    ans = 'Yes'
    for i,j in enumerate(s):
        if i%2==0 and j not in step_odd:
            ans = 'No'
        elif i%2!=0 and j not in step_even:
            ans = 'No'
        else:
            pass
    print(ans) def resolve():
    s = input()
    step_odd = 'RUD'
    step_even = 'LUD'
    ans = 'Yes'
    for i,j in enumerate(s):
        if i%2==0 and j not in step_odd:
            ans = 'No'
        elif i%2!=0 and j not in step_even:
            ans = 'No'
        else:
            pass
    print(ans) resolve
def resolve():
    s = input()
    step_odd = 'RUD'
    step_even = 'LUD'
    ans = 'Yes'
    for i,j in enumerate(s):
        if i%2==0 and j not in step_odd:
            ans = 'No'
        elif i%2!=0 and j not in step_even:
            ans = 'No'
        else:
            pass
    print(ans)
resolve()