Problem:


Score: 200 points

Problem Statement

Takahashi will do a tap dance. The dance is described by a string S where each character is L, R, U, or D. These characters indicate the positions on which Takahashi should step. He will follow these instructions one by one in order, starting with the first character.

S is said to be easily playable if and only if it satisfies both of the following conditions:

Every character in an odd position (1-st, 3-rd, 5-th, \ldots) is R, U, or D.

Every character in an even position (2-nd, 4-th, 6-th, \ldots) is L, U, or D.

Your task is to print Yes if S is easily playable, and No otherwise.

Constraints

S is a string of length between 1 and 100 (inclusive).

Each character of S is L, R, U, or D.

Input

Input is given from Standard Input in the following format:

S

Output

Print Yes if S is easily playable, and No otherwise.

Sample Input 1

RUDLUDR

Sample Output 1

Yes

Every character in an odd position (1-st, 3-rd, 5-th, 7-th) is R, U, or D.

Every character in an even position (2-nd, 4-th, 6-th) is L, U, or D.

Thus, S is easily playable.

Sample Input 2

DULL

Sample Output 2

No

The 3-rd character is not R, U, nor D, so S is not easily playable.

Sample Input 3

UUUUUUUUUUUUUUU

Sample Output 3

Yes

Sample Input 4

ULURU

Sample Output 4

No

Sample Input 5

RDULULDURURLRDULRLR

Sample Output 5

Yes



Sample input:
RUDLUDR


Sample output:
Yes

Submission status: Runtime Error

Solution code:
s = list(input())
for i in range(len(s)):
  if i % 2 == 0:
    if not s[i] in "RUD":
      print ("No") 
      exit() 
  else: 
    if nit s[i] in "LUD":
      print("No")
      exit()
print("Yes"

Submission status: Runtime Error

Solution code:
import re
a = input()
b = re.compile('^([^L][^R])*[^L]?$')
if b.match(a):
print('Yes')
else:
print('No')

Submission status: Runtime Error

Solution code:
import re
a=input()
b=re.compile('^([^L][^R])*[^L]?$')
if b.match(a):
print('Yes')
else:
print('No')

Submission status: Runtime Error

Solution code:
import Re
a=input()
b=re.compile('^([^L][^R])*[^L]?$')
if a.match(b):
print('Yes')
else:
print('No')

Submission status: Runtime Error

Solution code:
import Re
a=input()
b=re.compile('^[^L][^R]*[^L]?$')
if a.match(b):
print('Yes')
else:
print('No')

Submission status: Runtime Error

Solution code:
import Re
a=input()
b=re.compile('^[^L][^R]*[^L]?$')
if a.match(b)
print('Yes')
else
print('No')

Submission status: Runtime Error

Solution code:
import Re
a=input()
b=re.compile('^([^L][^R]*[^L]?)$')
if a.match(b)
print('Yes')
else
print('No')

Submission status: Runtime Error

Solution code:
import re #与えられた条件にマッチする文字列か判定
a = input()
b = re.compile('^([^L][^R])*[^L]?$')
if match(a,b):
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
S = input()
res = "Yes"
for n in range(int(len(S/2))):
  if S[2*n+1] not in ["R","U","D"]:
    res = "No"
  if S[2*n] not in ["L","U","D"]:
    res = "No"
print(res)

Submission status: Runtime Error

Solution code:
s = input()
c = True
for i in range(len(s)):
    if i % 2 == 0:
        if s[i] != 'U' && s[i] != 'D' && s[i] != 'L':
            c = False
    if i % 2 == 1:
        if s[i] != 'U' && s[i] != 'D' && s[i] != 'R':
            c = False

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

Submission status: Runtime Error

Solution code:
S=input()
total=0

for i in range(ren(S)):
    if  (i%2)==0:
        if  (S[i]=='R')or(S[i]=='U')or(S[i]=='D'):
            pass
        else:
            total+=1
    else:
        if  (S[i]=='L')or(S[i]=='U')or(S[i]=='D'):
            pass
        else:
            total+=1

if  total==0:
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
S=input()
total=0

for i in range(ren(S)):
    if  i%2==0:
        if  (S[i]=='R')or(S[i]=='U')or(S[i]=='D'):
            pass
        else:
            total+=1
    else:
        if  (S[i]=='L')or(S[i]=='U')or(S[i]=='D'):
            pass
        else:
            total+=1

if  total==0:
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
S=input()
total=0

for i in range(ren(S)):
    if  i%2=0:
        if  (S[i]=='R')or(S[i]=='U')or(S[i]=='D'):
            pass
        else:
            total+=1
    else:
        if  (S[i]=='L')or(S[i]=='U')or(S[i]=='D'):
            pass
        else:
            total+=1

if  total==0:
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
S=input().split()
total=0

for i in range(ren(S)):
    if  i%2=0:
        if  (S[i]=='R')or(S[i]=='U')or(S[i]=='D'):
            pass
        else:
            total+=1
    else:
        if  (S[i]=='L')or(S[i]=='U')or(S[i]=='D'):
            pass
        else:
            total+=1

if  total==0:
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
S=input().split()
total=0

for i in range(ren(S)):
    if  i%2=0:
        if  S[i]=='R'or'U'or'D':
            pass
        else:
            total+=1
    elif  i%2=1:
        if  S[i]=='L'or'U'or'D':
            pass
        else:
            total+=1

if  total==0:
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
S=input().split()
total=0

for i in range(ren(S)):
    if  i%0:
        if  S[i]=='R'or'U'or'D':
            pass
        else:
            total+=1
    elif  i%1:
        if  S[i]=='L'or'U'or'D':
            pass
        else:
            total+=1

if  total==0:
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
S=input().split()
total=0

for i in range(ren(S))
    if  i%0:
        if  S[i]=='R'or'U'or'D':
            pass
        else:
            total+=1
    elif  i%1:
        if  S[i]=='L'or'U'or'D':
            pass
        else:
            total+=1

if  total==0:
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
import re

S = input()
P = re.compile()

if P.match(S):
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
line=input()

a=['R','U','D']
b=['L','U','D']
flag=True

for i in range(len(line)):
  if (i+1)%2==1:
    if line[i] not in a:
      fline=input()

a=['R','U','D']
b=['L','U','D']
flag=True

for i in range(len(line)):
  if not flag:
    print(flag)
    break
  if (i+1)%2==1:
    if line[i] not in a:
      flag=False
      print('No')
  else:
    if line[i] not in b:
      flag=False
      print('No')
if flag==True:
  print('Yes') lag==False
      print('No')
      break
  else:
    if line[i] not in b:
      flag==False
      print('No')
      break

if flag:
  print('Yes')

Submission status: Runtime Error

Solution code:
n = input()

flag = True
for i in range(N):
  if i%2 == 0:
    if n[i] == 'R' or n[i] == 'U' or n[i] == 'D':
      pass
    else:
      flag = False
      
  else:
    if n[i] == 'L' or n[i] == 'U' or n[i] == 'D':
      pass
    else:
      flag = False
      
if flag:
  print('Yes')
else:
  print('No')

Submission status: Runtime Error

Solution code:
S=input()
for i in range(0,int(len(S)):
  if S[2*i]!='L' and S[2*i+1]!='R':
    print('Yes')
  else:
    print('No')

Submission status: Runtime Error

Solution code:
S=input()
for i in range(int(S)):
  if S[2i]!='L' and S[2i+1]!='R':
    print('Yes')
  else:
    print('No')

Submission status: Runtime Error

Solution code:
s=input()
rud=["R","U","D"]
lud=["L","U","D"]
if rud in s[::2] and lud in s[1::2]:
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:
bool ans = True
S = input()
i = 0
while i < len(S):
  if S[i] == "L":
    ans = False
  i += 2
j = 1
while j < len(S):
  if S[j] == "R":
    ans = False
  j += 2
if ans:
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:
step = input()

ng = ["L", "R"]

for i in range(0, len(step)):
  if step[i] == ng[i%2]:
    return "No"
return "Yes"

Submission status: Runtime Error

Solution code:
S = input()
i = 1
ans = 'Yes'
for k in S:
    if (i % 2 = 1 and k == 'L') or (i % 2 = 0 and k == 'R'):
        ans = 'No'
        break
    i += 1
print(ans)

Submission status: Runtime Error

Solution code:
S = input()
Slist = list(S)
if 'R' in Slist[0::2] || 'U' in Slist[0::2] || 'D' in Slist[0::2]:
  if 'L' in Slist[0::1] || 'U' in Slist[0::1] || 'D' in Slist[0::1]:
    print('Yes')
  else:
    print('No')
else:
  print('No')

Submission status: Runtime Error

Solution code:
S = input()
Slist = list(S)
if 'R' Slist[0::2] || 'U' Slist[0::2] || 'D' Slist[0::2]:
  if 'L' Slist[0::1] || 'U' Slist[0::1] || 'D' Slist[0::1]:
    print('Yes')
  else:
    print('No')
else:
  print('No')

Submission status: Runtime Error

Solution code:
# 入力の取得
s = input()

even = ""
odd  = ""

#1文字ずつループ
for idx,s in enumerate(s):
    if idx = 0 or idx % 2 == 0:
        even += s
    else:
        odd += s

#判定
even = even.replace('R', '').replace('U', '').replace('D', '')
odd  = odd.replace('L', '').replace('U', '').replace('D', '')


if even = "" and odd = "":
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
dance = input()
dance.split()
out = False
for i in range(len(dance)):
  if dance[i] == "R":
    if i % 2 == 0:
      break
      print("No")
      out = True
  if dance[i] == "L
  	if i % 2 == 1:
      break
      print("No)
if out == False:
            print("Yes")

Submission status: Runtime Error

Solution code:
a=input()

for i in range(len(a)):
  if a[i]=='L' and i%2==0:
    print('No')
    exit()
    
  if a[i]=='R' and i%2==1:
    print('No')
  	exit()
  
print("Yes")

Submission status: Runtime Error

Solution code:
s=input()

i=0
flug=0
for x in range(1,len(s)+1):
    if(x%2==1):
        if(s[x] =='L'):
            flug=1
            break
    else:
        if(s[x] =='R'):
            flug=1
            break

if(flug==1):
    print("No")
else:
    print("Yes")

Submission status: Runtime Error

Solution code:
S = ' ' + input()
even_dance = ['R','U','D']
odd_dance = ['L','U','D']

flag = True

for i in range(1,len(S)):
	if i % 2 == 1:
      if S[i] in even_dance:
        pass
      else:
        flag = False
        break
        
	else:
      if S[i] in odd_dance:
        pass
      else:
        flag = False
        break
if flag:
  print('Yes')
else:
  print('No')

Submission status: Runtime Error

Solution code:
S = str(input())
step_count = 0
ans='Yes'
for step in S:
    step_count += 1
    if step_count%2:
        if step == 'L':
            ans='No'
            brake
            
    else:
        if step == 'R':
            ans='No'
            brake
print(ans)

Submission status: Runtime Error

Solution code:
# -*- coding: utf-8 -*-
s = input()

for i in range(0,len(s)):
  if (i%2==1)and(s[i]=="L"):
    print("No")
    exit()
  elif (i%2==0)s[i]=="R":
    print("No")
    exit()
print("Yes")

Submission status: Runtime Error

Solution code:
#coding:utf-8

S = input()

if ('L' in set(S[0::2]) or ('R' in set(S[1::2]):
    print('No')
else:
    print('Yes')

Submission status: Runtime Error

Solution code:
# coding: utf-8
def is_easy(steps):
  for i, step in enumerate(steps):
    if i % 2 == 0 and step == 'L':
      return 'No'
  	elif i % 2 == 1 and step == 'R':
      return 'No'
	return 'Yes'
  
steps = input()
print(is_easy(steps))

Submission status: Runtime Error

Solution code:
# coding: utf-8
import numpy as np
step_strings = {'L': 0, 'U': 1, 'D': 2, 'R': 3}
steps = input()
steps = np.array([step_strings[s] for s in steps])
steps_index = (np.arange(steps.size) + 1) % 2
if steps[steps_index == 0].max() < 3 and steps[steps_index == 1].min() > 0:
	print('Yes')
else:
  	print('No')

Submission status: Runtime Error

Solution code:
dance = input()
judge = True

for i in dance:
  if i % 2 == 0 and dance[i] == "R":
    judge = False
    break
  if i % 2 == 1 and dance[i] == "L":
    judge = False
    break

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

Submission status: Runtime Error

Solution code:
S=input()
e=S[0::2]
o=S[1::2]
for i in range(len(e)):
    if s[i]=="L":
        print("No")
        break
else:
  for j in range(len(o)):
    if o[j]=="R":
        print("No")
        break 
  else:
    print("Yes")

Submission status: Runtime Error

Solution code:
s=input()
i=0
for tmp in list(s):
  i+=1
  if i%2==0:
    if tmp in ['L','U','D']:
      continue
    else:
      x='N'
      break
  else:
    if tmp in ['R','U','D']:
      continue
    else:
      x='N'
      break
  break
if x=='N':
    print('No')
else:
    print('Yes')

Submission status: Runtime Error

Solution code:
s=input()
i=0
for tmp in s:
  i+=1
  if i%2==0:
    if tmp in ['L','U','D']:
    else:
      print('No')
      break
  break
  else:
    if tmp in ['R','U','D']:
    else:
      print('No')
      break
  break
print('Yes')

Submission status: Runtime Error

Solution code:
a = list(input())
i = 0
while True:
    odd = a[i]
    if odd == 'L':
        print('No')
        break
    i += 1
    if i+1 == len(a):
        print('Yes')
        break
    even = a[i]
    if even == 'R':
        print('No')
        break
    i += 1
    if i+1 == len(a):
        print('Yes')
        break

Submission status: Runtime Error

Solution code:
a = list(input())
i = 0
while True:
    odd = a[i]
    if odd == 'L':
        print('NO')
        break
    i += 1
    if i+1 == len(a):
        print('YES')
        break
    even = a[i]
    if even == 'R':
        print('NO')
        break
    i += 1
    if i+1 == len(a):
        print('YES')
        break

Submission status: Runtime Error

Solution code:
a = list(input())
i = 0
while True:
    odd = a[i]
    if odd == 'L':
        print('NO')
        break
    i += 1
    if i+1 == len(a):
        print('YES')
        break
    even = a[i]
    if even == 'R':
        print('NO')
        break
    i += 1
    if i+1 == len(a):
        print('YES')
        break

Submission status: Runtime Error

Solution code:
a = list(input())
i = 0
while True:
    odd = a[i]
    if odd == 'L':
        print('NO')
        break
    i += 1
    if i+1 == len(a):
        print('YES')
        break
    even = a[i]
    if even == 'R':
        print('NO')
    i += 1
    if i+1 == len(a):
        print('YES')
        break

Submission status: Runtime Error

Solution code:
a = list(input())
print(a)
i = 0
while True:
    odd = a[i]
    if odd == 'L':
        print('NO')
        break
    i += 1
    if i+1 == len(a):
        print('YES')
        break
    even = a[i]
    if even == 'R':
        print('NO')
    i += 1
    if i+1 == len(a):
        print('YES')
        break

Submission status: Runtime Error

Solution code:
s = input()

flg = 0
for i, c in enumrate(range(s)):
  if i%2!=0:
    if c in ["R", "U", "D"]:
      continue
    else:
      flg = 1
      break
  else:
    if c in ["R", "U", "D"]:
      continue
    else:
      flg = 1
      break
    
ans = "Yes" if flg else "No"
print(ans)

Submission status: Runtime Error

Solution code:
S = input()

odd = S[::2]
even = [1::2]

if 'L' in odd or 'R' in even:
    print('No')
else:
    print('Yes')

Submission status: Runtime Error

Solution code:
odd = ["R", "U", "D"]
even = ["L", "U", "D"]
s_list = list(input())

ans = "Yes"
for i in range(s_list):
  if i % 2 == 0:
    if not s_list[i] in odd:
      ans = "No"
  
  if i % 2 == 1:
    if not s_list[i] in even:
      ans = "No"

print(ans)

Submission status: Runtime Error

Solution code:
odd = ["R", "U", "D"]
even = ["L", "U", "D"]
s_list = list(input())

ans = "Yes"
for i in range(s_list):
  if i % 2 == 0:
	  if not s_list[i] in odd:
    	ans = "No"
  
  if i % 2 == 1:
	  if not s_list[i] in even:
    	ans = "No"

print(ans)

Submission status: Runtime Error

Solution code:
odd = ["R", "U", "D"]
even = ["L", "U", "D"]
s_list = list(input())

ans = "Yes"
for i in range(s_list):
  if i % 2 == 0:
	  if not data[i] in odd:
    	ans = "No"
  
  if i % 2 == 0:
	  if not data[i] in even:
    	ans = "No"

print(ans)

Submission status: Runtime Error

Solution code:
s = input()
for i in range(len()s):
  if i % 2 == 0 and s[i] == "R":
    print("No")
    exit()
  elif i % 2 == 1 and s[i] == "L":
    print("No")
    exit()
print("Yes")

Submission status: Runtime Error

Solution code:
s = input()
for i in range(len()s):
  if i % 2 == 0 && s[i] == "R":
    print("No")
    exit()
  elif i % 2 == 1 && s[i] == "L":
    print("No")
    exit()
print("Yes")

Submission status: Runtime Error

Solution code:
s = input()
for i in range(len()s):
  if i % 2 == 0 && s[i] == "R":
    print("No")
    exit()
  elif i % 2 == 1 %% s[i] == "L":
    print("No")
    exit()
print("Yes")

Submission status: Runtime Error

Solution code:
words = list(input())

for index, word in enumerate(words):
    isEven = index % 2 == 0
    if (isEven and word == "L") or ((not isEven) and word == "R") :
        continue
    else:
        print("NO")
        exit(-1)

print("YES")

Submission status: Runtime Error

Solution code:
S = list(input())

for c in range(1,len(S)+1):
    if c%2==1: 
        if S[c] == 'L':
            print('No')
            break
    else:
        if S[c] == 'R':
            print('No')
            break
else:
    print('Yes')

Submission status: Runtime Error

Solution code:
S=input()
a=S[::2]
b=S[1::2]
if 'L' not in a:
	if 'R' not in b:
		print('Yes')
    else:
		print('No')
else:
	print('No')

Submission status: Runtime Error

Solution code:
S=input()
a=S[::2]
b=S[1::2]
if 'L' not in a:
	if 'R' not in b:
		print('Yes')
    else:
    	print('No')
else:
	print('No')

Submission status: Runtime Error

Solution code:
S
a=S[::2]
b=S[1::2]
if 'L' not in a:
	pass
	if 'R' not in b:
		print('Yes')
else:
	print('No')

Submission status: Runtime Error

Solution code:
a=S[::2]
b=S[1::2]
if 'L' not in a:
	pass
	if 'R' not in b:
		print('Yes')
else:
	print('No')

Submission status: Runtime Error

Solution code:
x = list(input())
i = 0
while i < len(x) - 2:
    if  i % 2 == 0:
        if x[i] in ["L", "U", "D"]:
            edetector = True
        else:
            edetector = False
    else:
        if x[i] in ["R", "U", "D"]:
            odetector = True
        else:
            odetector = False
    i += 1

if edetector and odetector:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
x = list(input())
i = 0
while i < len(x) - 1:
    if  i % 2 == 0:
        if x[i] in ["L", "U", "D"]:
            edetector = True 
        else:
            edetector = False
    else:
        if x[i] in ["R", "U", "D"]:
            odetector = True 
        else:
            odetector = False
    i += 1
if edetector and odetector:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
import numpy as np
#N人　参加者
#Kポイント持ってスタート
#正解者以外のポイントは1づつ減る
#Q回正解者がでる
#得点が0以下で敗退
lst = input().split()

N = int(lst[0])
K = int(lst[1])
Q = int(lst[2])

if N < 2 or N > 100000:
    print('参加人数エラー')
    exit()

if K < 1 or K > 1000000000:
    print('ポイントエラー')
    exit()

if Q < 1 or Q > 100000:
    print('正解数エラー')
    exit()

p_list = np.linspace(K,K,num=N)

#得点計算
for i in range(Q):
    #正解者の入力を受け取って1マイナス
    collect = int(input()) - 1

    for j in range(N):
        if not j  == collect:
            p_list[j] = int(p_list[j]) - 1


#勝敗出力
k = 0
for k in range(N):
    if p_list[k] > 0:
        print('Yes')
    else:
        print('No')
    k += 1

Submission status: Runtime Error

Solution code:
import numpy as np
#N人　参加者
#Kポイント持ってスタート
#正解者以外のポイントは1づつ減る
#Q回正解者がでる
#得点が0以下で敗退
lst = input().split()

N = int(lst[0])
K = int(lst[1])
Q = int(lst[2])

if N < 2 or N > 100000:
    print('参加人数エラー')
    exit()

if K < 1 or K > 1000000000:
    print('ポイントエラー')
    exit()

if Q < 1 or Q > 100000:
    print('正解数エラー')
    exit()

p_list = np.linspace(K,K,num=N)

#得点計算
for i in range(Q):
    #正解者の入力を受け取って1マイナス
    collect = int(input()) - 1

    j = 0
    for j in range(N):
        if not j  == collect:
            p_list[j] = int(p_list[j]) - 1
        j += 1

#勝敗出力
k = 0
for k in range(N):
    if p_list[k] > 0:
        print('Yes')
    else:
        print('No')
    k += 1

Submission status: Runtime Error

Solution code:
import numpy as np
#N人　参加者
#Kポイント持ってスタート
#正解者以外のポイントは1づつ減る
#Q回正解者がでる
#得点が0以下で敗退
lst = input().split()

N = int(lst[0])
K = int(lst[1])
Q = int(lst[2])

if N < 2 or N > 100000:
    print('参加人数エラー')
    exit()

if K < 1 or K > 1000000000:
    print('ポイントエラー')
    exit()

if Q < 1 or Q > 100000:
    print('正解数エラー')
    exit()

#p_list = []
#for i in range(N):
#    p_list.append(K)
p_list = np.linspace(K,K,num=N)
print(p_list)
#得点計算
for i in range(Q):
    #正解者の入力を受け取って1マイナス
    collect = int(input()) - 1

    j = 0
    for j in range(N):
        if not j  == collect:
            p_list[j] = int(p_list[j]) - 1
        j += 1

#勝敗出力
k = 0
for k in range(N):
    if p_list[k] > 0:
        print('Yes')
    else:
        print('No')
    k += 1

Submission status: Runtime Error

Solution code:
grrhuagl

Submission status: Runtime Error

Solution code:
n, k, q = map(int, input().split())
ar = [k for i in range(n)]
for i in range(q):
  index = int(input())
  ar[index-1] += 1
for i in range(n):
  if ar[i] - q > 0:
    print("Yes")
  else:
    print("No")

Submission status: Runtime Error

Solution code:
a = input()
b = len(a)
for i in range(0,b):
  if (i+1) % 2 ==0:
    if a[i] == "R":
      print("No")
  
  elif (i+1) % 2 ==1:
    ifa[i] == "L":
      print("No")
      
else:
  print("Yes")

Submission status: Runtime Error

Solution code:
# coding: utf-8

import sys

s=input()
for i in range(1,int(len(s))+1):
    if i%2==0 and (s[i]=="L" or s[i]=="U" or s[i]=="D"):
        print("Yes")
    elif i%2!=0 and (s[i]=="R" or s[i]=="U" or s[i]=="D"):
        print("Yes")
    else:
        print("No")

Submission status: Runtime Error

Solution code:
import sys

s=input()

for i in range(len(s)):
  if i%2==0:
    if s[i]==="L":
      print("No")
      sys.exit()
      
  else:
    if s[i]=="R":
      print("No")
      sys.exit()
      
print("Yes")

Submission status: Runtime Error

Solution code:
s=input()

for i in range(len(s)):
  if i%2==0:
    if s[i]==="L":
      print("No")
      sys.exit()
      
  else:
    if s[i]=="R":
      print("No")
      sys.exit()
      
print("Yes")

Submission status: Runtime Error

Solution code:
S = list(map(int, input().split()))
Sodd = S.Slice[::2]
Seven = S.Slice[1::2]
if "L" in Sodd:
  print("No")
elif "R" in Seven:
  print("No")
else:
  Print("Yes")

Submission status: Runtime Error

Solution code:
S = input()
str_list = [*S]
even_str = str_list[0::2]
odd_str = str_list[1::2]
if ('L' in even_str):
  print('No')
elif ('R' in odd_str):
  print('No')
else:
  print('Yes')

Submission status: Runtime Error

Solution code:
S = input()
str_list = [*S]
even_str = str_list[0::2]
odd_str = str_list[1::2]
if ("L" in even_str):
  print("No")
elif ("R" in odd_str):
  print("No")
else:
  print("Yes")

Submission status: Runtime Error

Solution code:
s = list(input())
def easy_step(s) :
    s_even = s[::2]
    s_odd = [1::2]
    if ("L" in s_odd) or ("R" in s_even) :
        print("No")
    else :
        print("Yes")
easy_step(s)

Submission status: Runtime Error

Solution code:
s = list(input())
def easy_step(s) :
    s_odd = s[::2]
    s_even = [1::2]
    if ("L" in s_odd) or ("R" in s_even) :
        print("No")
    else :
        print("Yes")
easy_step(s)

Submission status: Runtime Error

Solution code:
s=input()
j=0
for i in range(len(s)):
    if j > len(s):
        print("Yes")
        break
    elif s[j]=="R" or s[j]=="U" or s[j]=="D":
        if j+2>len(s):
            print("Yes")
            break
        elif s[j+1]=="L" or s[j+1]=="U" or s[j+1]=="D":
            j+=2
        else:
            print("No")
            break
    else:
        print("No")
        break

Submission status: Runtime Error

Solution code:
S = input()
ans = "Yes"

for i in range(len(S)):
	if i%2 == 0:
		if !(S[i] in ('R', 'U', 'D')):
			ans = "No"
			break
	
	if i%2 == 1:
		if !(S[i] in ('L', 'U', 'D')):
			ans = "No"
			break
	
print(ans)

Submission status: Runtime Error

Solution code:
S = input()
ans = "Yes"

for i in range(len(S)):
	if S[i]%2 == 0:
		if !(S[i] in ('R', 'U', 'D')):
			ans = "No"
			break
	
	if S[i]%2 == 1:
		if !(S[i] in ('L', 'U', 'D')):
			ans = "No"
			break
	
print(ans)

Submission status: Runtime Error

Solution code:
S = input()

if S == 'Sunny':
    print('Cloudy')
elif S == 'Cloudy':
    print('Rainy')
else :
    print('Sunny'

Submission status: Runtime Error

Solution code:
# coding: utf-8
# Your code here!
l=list(input())
ans="Yes"
for i in range(len(l)):
    if(i%2==0):
        if(l[i]=="L"):
            ans="No"
    else:
        if(l[i]=="R"):
            ans="No"
print(ans)# coding: utf-8
# Your code here!
l=list(input())
ans="Yes"
for i in range(len(l)):
    if(i%2==0):
        if(l[i]=="L"):
            ans="No"
    else:
        if(l[i]=="R"):
            ans="No"
print(ans)

Submission status: Runtime Error

Solution code:
S=input().split()

if i>=0:
  if  S[0::2]=='L':
      print('No')
  elif  S[1::2]=='R':
      print('No')
  else:
      print('Yes')

Submission status: Runtime Error

Solution code:
import re
s = input()
odd = s[::2]
eve = s[1::2]
odd_re = re.compile(^[RUD]*$)
eve_re = re.compile(^[LUD]*$)
if odd_re.findall(odd) != [] and eve_re.findall(eve) != []:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
import re
s = input()
odd = s[::2]
eve = s[1::2]
odd_re = re.compile{^[RUD]*$}
eve_re = re.compile{^[LUD]*$}
if odd_re.findall(odd) != [] and eve_re.findall(eve) != []:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
S = input()
N = len(S)
ans = 'Yes'

for i in range(N):
    if S[2*i] == 'R':
        ans = 'No'
        break
    elif S[2*i+1] == 'L':
        ans ='No'
        break

print(ans)

Submission status: Runtime Error

Solution code:
S = input()
N = len(S)

for i in range(N):
    if S[2*i] == 'R':
        print('No')
        break
    else S[2*i+1] == 'L':
        print('No')
        break

print('Yes')

Submission status: Runtime Error

Solution code:
s = input()
for i in range(length(s)):
  if i%2 == 1:
    if not(s[i] == 'R' or s[i] == 'U' or s[i] == 'D'):
      print('No')
      exit()
  if i%2 == 0:
    if not(s[i] == 'L' or s[i] == 'U' or s[i] == 'D'):
      print('No')
      exit()
print('Yes')

Submission status: Runtime Error

Solution code:
s = input().strip()

def solve(s):
	for i in range(len(s)):
  		if i%2==0:
          if s[i] == "L":
          	return False
       	else:
          if s[i]=="R":
            return False
	return True
  
print("Yes" if solve(s) else "No")

Submission status: Runtime Error

Solution code:
s = input()

for i in range(s):
  if s[i] % 2 == 0 and s[i] == 'R':
    s = False
    break
  elif s[i] % 2 == 1 and s[i] == 'L':
    s = False
    break

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

Submission status: Runtime Error

Solution code:
S = input()

counter = 1
yorn = 1
for foot in S:
    if foot == 'R':
        if counter % 2 == 0:
            yorn=0
            break
    elif foot == 'L':
        if counter % 2 == 1:
            yorn = 0
            break
    counter++

if yorn == 1:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
S = input()

S = np.array( [S[i] for i in range(len(S))] )

if (S[0::2]=='L').any():
  print('No')
elif (S[1::2]=='R').any():
  print('No')
else:
  print('Yes')

Submission status: Runtime Error

Solution code:
S=str(input())
i=int()
0 <= i <= len(S)//2-1
if S[i*2]=="R":
    print("No")
elif S[i*2+1]=="L":
    print("No")
else :
    print("Yes")

Submission status: Runtime Error

Solution code:
S=str(input())
i=int()
0 <= i <= len(S)//2
if S[i*2]=="R":
    print("No")
elif S[i*2+1]=="L":
    print("No")
else :
    print("Yes")

Submission status: Runtime Error

Solution code:
S=str(input())
i=int()
0 <= i <= len(S)//2
if S[i*2]=="L":
    print("No")
elif S[i*2+1]=="R":
    print("No")
else :
    print("Yes")

Submission status: Runtime Error

Solution code:
S=str(input())
i=int()
0 <= i <= len(S)//2
if S[i*2]=="L":
    print("No")
elif S[i*2+1]=="R":
    print("No")
else :
    print(Yes)

Submission status: Runtime Error

Solution code:
S=input().split()

if i>=0:
  if  S[2*i]=='L':
      print('No')
  elif  S[2*i+1]=='R':
      print('No')

Submission status: Runtime Error

Solution code:
S = input()
slen = len(S)
i = int(0)
j = int(0)
while slen >= i:
	if i%2 == 1 and S[i] == "R","U","D":
		j = 0
	elif i%2 == 0 and S[i] == "L","U","D":
		j = 0
	else:
		j += 1
  i+1
if j == 0:
	print("No")
else:
	print("Yes")

Submission status: Runtime Error

Solution code:
s = input()
n = len(s)
count = 0
for i in range(0, n, 2):
    if s[i] == 'R':
        count += 1
for i in range(1, n, 2):
    if s[i] == 'L':
        count += 1
if count == n:
    print("Yes")
else print("No")

Submission status: Runtime Error

Solution code:
S=input()
N = len(S)
ans=0
for i in range(N+1):
    if i%2==0:
        if S[i]=='L':
            print('No')
        else:
            ans+=1
    else:
        if S[i]=='R':
            print('No')
        else:
            ans+=1
if ans==2:
    print('Yes')

Submission status: Runtime Error

Solution code:
s = input()
even = ['R', 'U', 'D']
odd = ['L', 'U', 'D']

for i, j in enumerate(s):
    if i % 2 == 0:
        if j not in odd:
            print('No')
            break
    else:
        if j not in even:
            printt('No')
            break
else:
    print('Yes')

Submission status: Runtime Error

Solution code:
s = input()
n = len(s)
a = 0
if n % 2 == 0:
  for i in range(0,n+1,2):
    if s[i] == "R":
      a = 1
      break
  for i in range(1,n,2):
    if s[i] == "L":
      a = 1
      break
if n % 2 == 1:
  for i in range(0,n,2):
    if s[i] == "R":
      a = 1
      break
  for i in range(1,n+1,2):
    if s[i] == "L":
      a = 1
      break
if a == 0:
  print("Yes")
if a == 1:
  print("No")

Submission status: Runtime Error

Solution code:
S = input()
S_o = S[::2]
S_e = S[1::2]
if 'L' in S_o or 'R' in _e:
    print('No')
else:
    print('Yes')

Submission status: Runtime Error

Solution code:
hoge = input().split()
i = 0
while i <= len(hoge):
  if i%2==0 and hoge[i] == ('L' or 'D' or 'U'):
    pass
  elif i%2==1 and hoge[i] == ('R' or 'D' or 'U'):
    pass
  else:
    break
  i+=1
if i == len(hoge):
  print('Yes')
else:
  print('No')

Submission status: Runtime Error

Solution code:
hoge = input().split()
i = 0
while i < range(len(hoge)):
  if i%2==0 and hoge[i] == ('R' or 'D' or 'U'):
    pass
  elif i%2==1 and hoge[i] == ('L' or 'D' or 'U'):
    pass
  else:
    break
  i+=1
if i == len(hoge):
  print('Yes')
else:
  print('No')

Submission status: Runtime Error

Solution code:
hoge = input().split()
i = 0
while i < range(len(hoge)):
  if i%2==0 and hoge[i] == 'L' or 'D' or 'U':
    pass
  elif i%2==1 and hoge[i] == 'R' or 'D' or 'U':
    pass
  else:
    break
  i+=1
if i == len(hoge):
  print('Yes')
else:
  print('No')

Submission status: Runtime Error

Solution code:
hoge = input().split()
while i < range(len(hoge)):
  if i%2==0 and hoge[i] == 'L' or 'D' or 'U':
    pass
  elif i%2==1 and hoge[i] == 'R' or 'D' or 'U':
    pass
  else:
    break
  i+=1
if i == len(hoge):
  print('Yes')
else:
  print('No')

Submission status: Runtime Error

Solution code:
hoge = input().split
while i < range(len(hoge)):
  if i%2==0 and hoge[i] == 'L' or 'D' or 'U':
    pass
  elif i%2==1 and hoge[i] == 'R' or 'D' or 'U':
    pass
  else:
    break
  i+=1
if i == len(hoge):
  print('Yes')
else:
  print('No')

Submission status: Runtime Error

Solution code:
hoge = input().strip()
int i = 0
while i < range(len(hoge)):
  if i%2==0 and hoge[i] == 'L' or 'D' or 'U':
    pass
  elif i%2==1 and hoge[i] == 'R' or 'D' or 'U':
    pass
  else:
    break
  i+=1
if i == len(hoge):
  print('Yes')
else:
  print('No')