TnT/Multi_CodeNet4Repair huggingface dataset:
Problem: 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.

Submission attempts (in order):
S = input()
l = list(S)

#odd loop
for i in range(1, len(S), 2):
    if l[i] == 'L':
        print('NO')
        exit()


for j in range(0, len(S), 2):
    if l[j] == 'R':
        print('NO')
        exit()

print('YES')

S = input()

#odd loop
for i in S[0:len(S)+1:2]:
    if i == 'L':
        print('NO')
        exit()

for j in S[1:len(S)+1:2]:
    if j == 'R':
        print('NO')
        exit()

print('YES')

S = input()
l = list(S)

#odd loop
for i in range(0,len(l),2):
    if l[i] == 'L':
        print('NO')
        exit()


for j in range(1, len(l), 2):
    if l[j] == 'R':
        print('NO')
        exit()

print('YES')

S = input()

for i in range(1, len(S), 2):
    if i == 'L':
        print('NO')
        exit()

for j in range(0, len(S), 2):
    if j == 'R':
        print('NO')
        exit()

print('YES')

S = input()

#odd loop
for i in range(1, len(S), 2):
    if i == 'L':
        print('NO')
        exit()


for j in range(0, len(S), 2):
    if j == 'R':
        print('NO')
        exit()

print('YES')

S = input()
l = list(S)

#odd loop
for i in range(0,len(S),2):
    if l[i] == 'L':
        print('NO')
        exit()


for j in range(1, len(S), 2):
    if l[j] == 'R':
        print('NO')
        exit()

print('YES')

S = input()

#odd loop
for i in S[0::2]:
    if i == 'L':
        print('NO')
        exit()

for j in S[1::2]:
    if j == 'R':
        print('NO')
        exit()

print('YES')

S = input()
l = list(S)

#odd loop
for i in range(0,len(l), 2):
    if l[i] == 'L':
        print('NO')
        exit()


for j in range(1, len(l), 2):
    if l[j] == 'R':
        print('NO')
        exit()

print('YES')

S = input()
l = list(S)

#odd loop
for i in range(0, len(l), 2):
    if l[i] == 'L':
        print('No')
        exit()


for j in range(1, len(l), 2):
    if l[j] == 'R':
        print('No')
        exit()

print('Yes')

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Wrong Answer

Wrong Answer

Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
S = input()

odd = list(S[::2])
even = list(S[1::2])
xx = "No"
x1 = ""
x2 = ""

for i in range(len(odd)):
  check = 0
  if odd[i] == "L" or "U" or "D":
    check += 1
  
if check == len(odd):
  x1 = "Y"
  
for i in range(len(even)):
  check2 = 0
  if even[i] == "R" or "U" or "D":
    check2 += 1
 
if check2 == len(even):
  x2 = "Y"
  
  
if x1 and x2 == "Y":
  xx = "Yes"
  
  
print(xx)



s = input()

if 'L' in s[::2] or 'R' in s[1::2]:
    ans = 'No'
else:
    ans = 'Yes'
print(ans)


Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
b = True
s = input()
for i in range(0, len(s)):
  if(i % 2 == 0):
    if s[i] == 'R':
      b = False
  else:
    if s[i] == 'L':
      b = False
if b:
  print("Yes")
else:
  print("No")

b = True
s = input()
for i in range(0, len(s)):
  if(i % 2 == 1):
    if s[i] == 'R':
      b = False
  else:
    if s[i] == 'L':
      b = False
if b:
  print("Yes")
else:
  print("No")

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
import sys
def main():
    input = sys.stdin.readline
    S = input()
    s_len = len(list(S))
    for i in range(s_len):
        s = S[i]
        ans = "Yes"
        if s == "U" or s == "D":
            pass
        else:
            if i % 2 == 0:
                if s == "R":
                    pass
                else:
                    ans = "No"
                    break
            else:
                if s == "L":
                    pass
                else:
                    ans = "No"
                    break

    print(ans)
if __name__ == '__main__':
    main()

def main():
    S = input()
    s_len = len(list(S))
    for i in range(s_len):
        s = S[i]
        ans = "Yes"
        if s == "U" or s == "D":
            pass
        else:
            if i % 2 == 0:
                if s == "R":
                    pass
                else:
                    ans = "No"
                    break
            else:
                if s == "L":
                    pass
                else:
                    ans = "No"
                    break
 
    print(ans)
if __name__ == '__main__':
    main()

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
s = input()
flag = 0

for i, c in enumerate(s):
  if (i % 2 == 0) & (c == "R"):
    flag = 1
  elif (i % 2 == 1) & (c == "L"):
    flag = 1

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

s = input()
flag = 0

for i, c in enumerate(s):
  if (i % 2 == 0) and (c == "L"):
    flag = 1
  elif (i % 2 == 1) and (c == "R"):
    flag = 1

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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
s = input()
s_list =  list(s)
jun = 0
ans = 1

while(len(s_list)):
    if jun % 2 == 0:
        if s_list[jun] != "R" or s_list[jun] != "U" or s_list[jun] != "D":
            ans = 0
    if jun % 2 == 1:
        if s_list[jun] != "L" or s_list[jun] != "U" or s_list[jun] != "D":
            ans = 0
    jun += 1
    if jun == len(s_list):
      break
if ans == 1:
    print("Yes")
else:
    print("No")

s = [i for i in input().split()]
s_list = list(s)

print(s_list)

s = input()
s_list =  list(s)
jun = 0
ans = 1

while(len(s_list)):
    if jun % 2 == 0:
        if s_list[jun] == "L":
            ans = 0
    if jun % 2 == 1:
        if s_list[jun] == "R":
            ans = 0
    jun += 1
    if jun == len(s_list):
      break
if ans == 1:
    print("Yes")
else:
    print("No")

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
strs = input()

for str in strs:
  if i % 2 == 0:
    if (i == "L") or (i == "U") or (i == "D"):
      continue
    else:
      print("No")
      break
  else:
    if (i == "R") or (i == "U") or (i == "D"):
      continue
    else:
      print("No")
      break
else:
  print("Yes")
    

strs = input()
 
for i in range(len(strs)):
  if i % 2 == 0:
    if (strs[i] == "L") or (strs[i] == "U") or (strs[i] == "D"):
      continue
    else:
      print("No")
      break
  else:
    if (strs[i] == "R") or (strs[i] == "U") or (strs[i] == "D"):
      continue
    else:
      print("No")
      break
else:
  print("Yes")

strs = input()
 
for i in range(len(strs)):
  if !(i % 2 == 0):
    if (strs[i] == "L") or (strs[i] == "U") or (strs[i] == "D"):
      continue
    else:
      print("No")
      break
  else:
    if (strs[i] == "R") or (strs[i] == "U") or (strs[i] == "D"):
      continue
    else:
      print("No")
      break
else:
  print("Yes")

strs = input()
 
for i in range(len(strs)):
  if i % 2 != 0:
    if (strs[i] == "L") or (strs[i] == "U") or (strs[i] == "D"):
      continue
    else:
      print("No")
      break
  else:
    if (strs[i] == "R") or (strs[i] == "U") or (strs[i] == "D"):
      continue
    else:
      print("No")
      break
else:
  print("Yes")

Verdicts: Runtime Error

Wrong Answer

Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
#a,b = map(int,input().split())
#A = list(map(int,input().split()))
S = str(input())
if('L' in S[0::2] or 'R' in S[1::2]):
    print('No')
else:
    print('yes')

#a,b = map(int,input().split())
#A = list(map(int,input().split()))
S = str(input())
if('L' in S[0::2] or 'R' in S[1::2]):
    print('No')
else:
    print('Yes')

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
F = input()
o = {"R", "U","D"}
e = {"L", "U","D"}
for i in range(len(F)):
    if i % 2 == 0:
        if F[i] not in e:
            print("No")
            break
    else:
        if F[i] not in o:
            print("No")
            break
print("Yes")

F = input()
o = {"R", "U","D"}
e = {"L", "U","D"}
flag = False
for i in range(len(F)):
    if( i+1) % 2 == 1:
        if F[i] not in o:
            print("No")
            flag = True
            break
    else:
        if F[i] not in e:
            print("No")
            flag = True
            break
if flag == False:
    print("Yes")

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
s=input()

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

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

s=input()

i=0

for x in range(len(s)):
    if(i%2==1):
        if(s[i] !='R' or 'U' or 'D'):
            flug=1
            break
    else:
        if(s[i] !='L' or 'U' or 'D'):
            flug=1
            break

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

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")

s=input()

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

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

Verdicts: Wrong Answer

Wrong Answer

Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
s=input()
i,b=0,0
while i<len(s):
	if (((s[i]=='R') & (i%2==1))|((s[i]=='L') & (i%2==0))):
		b=1
		break
	i+=1
if(b):
	print('NO')
else:
	print('YES')

s=input()
i,b=0,0
while i<len(s):
  if (((s[i]=='R') & (i%2==0))|((s[i]=='L') & (i%2==1))):
    b=1
if(b):
  print('NO')
else:
  print('YES')
  

s=input()
i,b=0,0
while i<len(s):
	if (((s[i]=='R') & (i%2==1))|((s[i]=='L') & (i%2==0))):
		b=1
		break
	i+=1
if(b):
	print('YES')
else:
	print('NO')

s=input()
i,b=0,0
while i<len(s):
  if (((s[i]=='R') & (i%2==0))|((s[i]=='L') & (i%2==1))):
    b=1
    break
if(b):
  print('NO')
else:
  print('YES')

s=input()
i,b=0,0
while i<len(s):
	if (((s[i]=='R') & (i%2==1))|((s[i]=='L') & (i%2==0))):
		b=1
		break
	i+=1
if(b):
	print('NO')
else:
	print('YES')

s=input()
i,b=0,0
while i<len(s):
	if (((s[i]=='R') & (i%2==1))|((s[i]=='L') & (i%2==0))):
		b=1
		break
	i+=1
if(b):
	print('No')
else:
	print('Yes')

Verdicts: Wrong Answer

Time Limit Exceeded

Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
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")

dance = input()
judge = True

for i in range(len(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")

dance = input()
judge = True

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

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

Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
s = input()
ans = 0
for i in range(len(s)):
  if ans != 0:
    print('No')
    exit()
  if i % 2 == 0:
    if s[i] == 'R':
      ans += 1
  else:
    if s[i] == 'L':
      ans += 1
print('Yes')
    


s = input()
for i in range(len(s)):
  if ans != 0:
    print('No')
    exit()
  if i % 2 == 0:
    if s[i] == 'R':
      ans += 1
  else:
    if s[i] == 'L':
      ans += 1
print('Yes')
    

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

Verdicts: Wrong Answer

Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
import sys
S=input()
if n>1:
    for i in range(n//2):
        s=S[2*i]
        if s=="L":
            print("No")
            sys.exit()
        s=S[2*i+1]
        if s=="R":
            print("No")
            sys.exit()
if n%2==1:
    s=S[-1]
    if s=="L":
        print("No")
        sys.exit()
print("Yes")

import sys
S=input()
if len(S)>1:
    for i in range(n//2):
        s=S[2*i]
        if s=="L":
            print("No")
            sys.exit()
        s=S[2*i+1]
        if s=="R":
            print("No")
            sys.exit()
if len(S)%2==1:
    s=S[-1]
    if s=="L":
        print("No")
        sys.exit()
print("Yes")

import sys
S=input()
if len(S)>1:
    for i in range(n//2):
        s=S[2*i]
        if s=="L":
            print("No")
            sys.exit()
        s=S[2*i+1]
        if s=="R":
            print("No")
            sys.exit()
if n%2==1:
    s=S[-1]
    if s=="L":
        print("No")
        sys.exit()
print("Yes")

import sys
S=input()
if len(S)>1:
    for i in range(n//2):
        s=S[2*i]
        if s=="L":
            print("No")
            sys.exit()
        s=S[2*i+1]
        if s=="R":
            print("No")
            sys.exit()
if n%2==1:
    s=S[-1]
    if s=="L":
        print("No")
        sys.exit()
print("Yes")

import sys
S=input()
for i in range(n//2):
    s=S[2*i]
    if s=="L":
        print("No")
        sys.exit()
    s=S[2*i+1]
    if s=="R":
        print("No")
        sys.exit()
if n%2==1:
    s=S[-1]
    if s=="L":
        print("No")
        sys.exit()
print("Yes")

import sys
S=input()
n=len(S)
if n>1:
    for i in range(n//2):
        s=S[2*i]
        if s=="L":
            print("No")
            sys.exit()
        s=S[2*i+1]
        if s=="R":
            print("No")
            sys.exit()
if n%2==1:
    s=S[-1]
    if s=="L":
        print("No")
        sys.exit()
print("Yes")

Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
S = list(input())
print(S)
frag = 0
for i in range(len(S)):
    if i % 2 == 0:
        if S[i] != "R" and S[i] != "U" and S[i] != "D":
            frag += 1
    if i % 2 == 1:
        if S[i] != "L" and S[i] != "U" and S[i] != "D":
            frag += 1
if frag != 0:
    print("No")
else:
    print("Yes")


S = list(input())
frag = 0
for i in range(len(S)):
    if i % 2 == 0:
        if S[i] != "R" and S[i] != "U" and S[i] != "D":
            frag += 1
    if i % 2 == 1:
        if S[i] != "L" and S[i] != "U" and S[i] != "D":
            frag += 1
if frag != 0:
    print("No")
else:
    print("Yes")


Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
S = list(input())
for s in len(S):
  if s % 2 == 1:
    if S[s] == "L":
      print("No")
      break
  else:
    if S[s] == "R":
      print("No")
      break
else:
  print("Yes")
      
    

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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
S = input()
O = ['R','U','D']
E = ['L','U','D']
ng = False
for i in range(len(S)):
  if i % 2 == 0:
    if S[i] not in O:
      ng = True
      break
  else:
    if S[i] not in E:
      ng = True
      break
print('No') if ng print('Yes')

S = input()
O = ['R','U','D']
E = ['L','U','D']
ng = False
for i in range(len(S)):
  if i % 2 == 0:
    if S[i] not in O:
      ng = True
      break
  else:
    if S[i] not in E:
      ng = True
      break
print('No') if ng else print('Yes')


Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
S = list(input())
i = 0
for s in range(len(S)):
  t = s + 1
  if S[s] == "U" or S[s] =="D":
    i += 1
  if t%2 !=0 :
    if S[s] == "R":
      i +=1
  if t%2==0:
    if S[s] == "L":
      i += 1
print(i)
if i == len(S):
  print("Yes")
else:
  print("No")

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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
import sys

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

import sys

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


Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
justified=True
S=list(input())
check1=["R","U","D"]
check2=["L","U","D"]
for j in range(len(S)):
    if( j)%2==0:
        if  S[j] in check1:
            continue
        else:
            justified=False
            break
        
    if (j)%2==1:
        if S[j] in check2:
            continue
        else:
            justified=False
            break
if justified:
    print("YES")
else:
    print("NO")

justified=True
S=list(input())
check1=["R","U","D"]
check2=["L","U","D"]
for j in range(len(S)):
    if( j)%2==0:
        if  S[j] in check1:
            continue
        else:
            justified=False
            break
        
    if (j)%2==1:
        if S[j] in check2:
            continue
        else:
            justified=False
            break
if justified:
    print("Yes")
else:
    print("No")

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
s = input()

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

print('Yes')

s = input()

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

print('Yes')


Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
a = input()

b =  ['R','U','D']
c =  ['L','U','D']
f= 0
for n,x in enumerate(a):
    if n%2==0 and x not in b : f = 1
    else:
        if x not in c : f = 1
def Y(a,t = 0):
    if a==t : print('YES')
    else : print('NO')
def y(a, t =0):
    if a==t : print('Yes')
    else : print('No')
y(f)

a = input()

b =  ['R','U','D']
c =  ['L','U','D']
f= 0
for n,x in enumerate(a):
    if n%2==0 and x not in b : f = 1
    elif n%2==1 and x not in c : f = 1
def Y(a,t = 0):
    if a==t : print('YES')
    else : print('NO')
def y(a, t =0):
    if a==t : print('Yes')
    else : print('No')
y(f)

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
s = input()
f = 0
for i in range(len(s)):
  if i % 2 == 1 and not (s[i] == 'R' or s[i] == 'U' or s[i] == 'D'):
    f = 1
  if i % 2 == 0 and not (s[i] == 'L' or s[i] == 'U' or s[i] == 'D'):
    f = 1
if f:
  print("No")
else:
  print("Yes")

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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
N=str(input())
if 'R' in N[0::2] or 'L' in N[1::2]:
    print('No')
else:
    print('Yes')

N=str(input())
if 'L' in N[0::2] or 'R' in N[1::2]:
    print('No')
else:
    print('Yes')

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
S = input()

for s in S[0::2]:
    if s != 'R' and s != 'U' and s != 'D':
        print('No')
        quit()

for s in S[1::2]:
    if S[i] != 'L' and S[i] != 'U' and S[i] != 'D':
        print('No')
        quit()

print('Yes')


S = input()

for s in S[0::2]:
    if s != 'R' and s != 'U' and s != 'D':
        print('No')
        quit()

for i in S[1::2]:
    if S[i] != 'L' and S[i] != 'U' and S[i] != 'D':
        print('No')
        quit()

print('Yes')


S = input()

for i in range(0, len(S), 2):
    if not (S[i] == 'L' or S[i] == 'U' or S[i] == 'D'):
        print('No')
        quit()

for i in range(1, len(S), 2):
    if not (S[i] == 'R' or S[i] == 'U' or S[i] == 'D'):
        print('No')
        quit()


S = input()

for s in S[0::2]:
    if s != 'R' and s != 'U' and s != 'D':
        print('No')
        quit()

for s in S[1::2]:
    if s != 'L' and s != 'U' and s != 'D':
        print('No')
        quit()

print('Yes')


Verdicts: Runtime Error

Runtime Error

Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
s = input()
is_ok = True
for i in range(len(s)):
    if i % 2 == 0 and s[i] == "L":
        is_ok = False
        break
    if i % 2 == 1 and s[i] == "R":
        is_ok = False
        break
print("Yes" is_ok else "No")

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


Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
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')



S = ' ' + input()  
flag = True 

for i in range(1,len(S)): 
    if i % 2 == 1:  
        if S[i] == 'L':    
            flag = False   
            break
    else:   
        if S[i] =='R':     
            flag = False
            break

print('Yes' if flag else 'No')


Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
S=input()

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

S=input()

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


Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
import sys
s = sys.stdin.readline()
flag = True
i = 0
while i < len(s):
  if i % 2:
    if s[i] != 'L' and s[i] != 'U' and s[i] != 'D':
      flag = False
      break
  else:
    if s[i] != 'R' and s[i] != 'U' and s[i] != 'D':
      flag = False
      break
  i += 1
if flag:
  print('Yes')
else:
  print('No')


import sys
s = sys.stdin.readline()
flag = True
i = 0
while i < len(s):
  if i % 2:
    if s[i] != 'R' and s[i] != 'U' and s[i] != 'D':
      flag = False
      break
  else:
    if s[i] != 'L' and s[i] != 'U' and s[i] != 'D':
      flag = False
      break
  i += 1
if flag:
  print('Yes')
else:
  print('No')

import sys
s = sys.stdin.readline().strip()
flag = True
i = 0
while i < len(s):
  if i % 2:
    if s[i] != 'L' and s[i] != 'U' and s[i] != 'D':
      flag = False
      break
  else:
    if s[i] != 'R' and s[i] != 'U' and s[i] != 'D':
      flag = False
      break
  i += 1
if flag:
  print('Yes')
else:
  print('No')


Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
#!/usr/bin/env python
# -*- coding: utf-8 -*-

from sys import stdin
import math


str_list  = stdin.readline().rstrip()


kisu = ['R','U','D']
gusu = ['L','U','D']


for i in range(len(str_list)):
    
    if i % 2 == 0:
        if str_list[i] in kisu:
            pass
        else:
            ans='no'
            break

    else:
        if str_list[i] in gusu:
            pass
        else:
            ans='no'
            break
else:
    ans='yes'

print(ans)
            





#!/usr/bin/env python
# -*- coding: utf-8 -*-

from sys import stdin
import math


str_list  = stdin.readline().rstrip()


kisu = ['R','U','D']
gusu = ['L','U','D']


for i in range(len(str_list)):
    
    if i % 2 == 0:
        if str_list[i] in kisu:
            pass
        else:
            ans='No'
            break

    else:
        if str_list[i] in gusu:
            pass
        else:
            ans='No'
            break
else:
    ans='Yes'

print(ans)
            





Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
s = list(input())

if s[::2] in "L" or s[1::2] in "R":
    print("No")
else:
    print("Yes")

s = input()

if "L" in s[::2] or "R" in s[1::2]:
    print("No")
else:
    print("Yes")

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
flg=0
for i in range(0,len(s)-1,2):
    if s[i] not in ["R","U","D"]:
        flg=1
    if s[i+1] not in ["L","U","D"]:
        flg=1
if(flg==1):
    print("No")
else: print("Yes")

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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
S=list(input())
a=S[::2]
b='Yes'
for i in a:
  if i!='R' or i!='U' or i!='D':
    b='No'
    break
c=S[1::2]
for j in c:
  if j!='L' or j!='U' or j!='D':
    b='No'
    break
print(b)
  



S=list(input())
a=S[::2]
c=S[1::2]
b='Yes'
for i in a:
  if i!='R' or i!='U' or i!='D':
    b='No'
for j in c:
  if j!='L' or j!='U' or j!='D':
    b='No'
print(b)


S=list(input())
a=S[::2]
c=S[1::2]
b='Yes'
for i in a:
  if i!='R' or i!='U' or i!='D':
    b='No'
for j in c:
  if j!='L' or i!='U' or i!='D':
    b='No'
print(b)


S=list(input())
a=S[::2]
b='Yes'
for i in a:
  if i!='R' and i!='U' and i!='D':
    b='No'
    break
c=S[1::2]
for j in c:
  if j!='L' and j!='U' and j!='D':
    b='No'
    break
print(b)
  



Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
S=input()
flag = True

for i in range(len(a)):
  if i%2==0 and S[i] == R:
    print('No')
    flag = False
    break
  elif i%2==1 and S[i] == L:
    print('No')
    flag = False
    break
if flag:
  print('Yes')
  	

S = input()
flag = True
 
for i in range(len(S)):
  if i%2==0 and S[i] == "R":
    print('No')
    flag = False
    break
  elif i%2==1 and S[i] == "L":
    print('No')
    flag = False
    break
if flag:
  print('Yes')

S=input()
flag = True
 
for i in range(len(S)):
  if i%2==0 and S[i] == R:
    print('No')
    flag = False
    break
  elif i%2==1 and S[i] == L:
    print('No')
    flag = False
    break
if flag:
  print('Yes')

S = input()
flag = True
 
for i in range(len(S)):
  if i%2==0 and S[i] == "R":
    print('No')
    flag = False
    break
  elif i%2==1 and S[i] == "L":
    print('No')
    flag = False
    break
if flag:
  print('Yes')

S = input()
flag = True
 
for i in range(len(S)):
  if i%2==0 and S[i] == "R":
    print('No')
    flag = False
    break
  if i%2==1 and S[i] == "L":
    print('No')
    flag = False
    break
if flag:
  print('Yes')

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

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


Verdicts: Runtime Error

Wrong Answer

Runtime Error

Wrong Answer

Wrong Answer

Wrong Answer

Accepted