TnT/Multi_CodeNet4Repair huggingface dataset:
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
x,k,d=map(int,input().split())
x=abs(x)
sa=x//d
ans=x
pbk,mbk=0,0
bk1,bk2,bk3=1,1,1
mansbk,pansbk=0,0
if sa>=k:
  ans=x-d*k
else:
  ans=x-d*sa
  k=k-sa
  for i in range(k):
    mansbk=abs(ans-d)
    pansbk=abs(ans+d)
    if mansbk!=pansbk:
      ans=min(mansbk,pansbk)
      if bk3!=1:
        bk1=min(mansbk,pansbk)
        bk2=max(mansbk,pansbk)
        ans=ans if (k-i)%2==0 else bk1
        break
      else:
        bk3=max(mansbk,pansbk) 
    else:
      ans=0 if (k-i)%2==0 else d
      break
    pbk=max(mansbk,pansbk)
    mbk=min(mansbk,pansbk)
print(ans)

s=input()
ans=0
bk=0
for i in range(3):
  if s[i]=="R":
    bk+=1
  else:
    if ans<bk:
      ans=bk
    bk=0
if ans<bk:
  ans=bk
print(ans)

Verdicts: Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
N = int(input())
L = list(map(int,input().strip().split()))
L_sort = L.sort()
count = 0
for i in range(N-2):
	for j in range(i+1 , N):
		for k in range(j+1 , N):
        		if L_sort(i) + L_sort(j) > L_sort(k):
            		count += 1
print(count)


N = int(input())
L = list(map(int,input().strip().split()))
L_sort = L.sort()
count = 0
for i in range(N-2):
	for j in range(i+1 , N):
		for k in range(j+1 , N):
        	if L_sort(i) + L_sort(j) > L_sort(k):
            	count += 1
print(count)

input_weather = input()
if input_weather.count('RRR') == 1:
	print(3)
elif input_weather.count('RR') == 1:
    print(2)
elif input_weather.count('R') >= 1:
    print(1)
else :
    print(0)



Verdicts: Runtime Error

Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
X, K, D = map(int, input().split())
X=abs(X)
if D>=X and K%2==0:
    ans=X
elif D>=X and K%2==1:
    ans=D-X
elif D<X and K*D<X:
    ans=X-K*D
else:
    ans=X%D
    if (X-ans)%2==0:
        ans=D-ans
print(ans)

S=input()
for i in range(0,3):
    if S[0]=="R" and S[1]=="R" and S[2]=="R":
        x=3
    elif S[0]=="R" and S[1]=="R":
        x=2
    elif S[1]=="R" and S[2]=="R":
        x=2
    elif S[0]=="R" or S[1]=="R" or S[2]=="R":
        x=1
    else:
        x=0
print(x)

Verdicts: Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

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

if s in "R":
    ans = 1
if s in "RR":
    ans = 2
if s in "RRR":
    ans = 3
print(ans)


s = input()
ans = 0
if s in "R":
    ans = 1
if s in "RR":
    ans = 2
if s in "RRR":
    ans = 3
print(ans)

s = input()
ans = 0
if "R" in s:
    ans = 1
if "RR" in s:
    ans = 2
if "RRR" in s:
    ans = 3
print(ans)

Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
print("A.py")

S=input()

if "RRR" in S:
	print(3)
elif "RR" in S:
	print(2)
elif "R" in S:
	print(1)
else: 
	print(0)

Verdicts: Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
a = input()
o = 0
for i in range(2):
  if a[i] == a[i + 1]:
    o += 1
print(o)

a = input()
o = 0
if 'R' in a[:]:
  o += 1
for i in range(2):
  if a[i] == 'R' and a[i+1] == 'R':
    o += 1
print(o)

Verdicts: Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
from time import time
def timer(func):
    def f(*args, **kwargs):
        before = time()
        rv = func(*args, **kwargs)
        after = time()
        print('temps écoulé', after - before)
        return rv
    return f

@timer
def A(S): 
    nb = 0
    if S == 'RSR':
        print(2)
        exit
    else:
        for i in S:
            if i == 'R':
                nb = nb+1
        print(nb)


@timer
def B():
    ...

@timer
def C():
    ...


S = input()
A(S)


from time import time
def timer(func):
    def f(*args, **kwargs):
        before = time()
        rv = func(*args, **kwargs)
        after = time()
        print('temps écoulé', after - before)
        return rv
    return f

@timer
def A(S): 
    nb = 0
    if S == 'RSR':
        print(1)
        exit
    else:
        for i in S:
            if i == 'R':
                nb = nb+1
        print(nb)


@timer
def B():
    ...

@timer
def C():
    ...


S = input()
A(S)


from time import time
def timer(func):
    def f(*args, **kwargs):
        before = time()
        rv = func(*args, **kwargs)
        after = time()
        print('temps écoulé', after - before)
        return rv
    return f


def A(S): 
    nb = 0
    if S == 'RSR':
        print(1)
        exit
    else:
        for i in S:
            if i == 'R':
                nb = nb+1
        print(nb)


@timer
def B():
    ...

@timer
def C():
    ...


S = input()
A(S)


Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
w=str(input())
if w==RRR:
    print(3)
elif w==SRR:
    print(2)
elif w==RRS:
    print(2)
elif w==RSR:
    print(1)
elif w==RSS:
    print(1)
elif w==SRS:
    print(1)
elif w==SSR:
    print(1)
else :
    print(0)

w=input()
if w=="RRR":
    print(3)
elif w=="SRR":
    print(2)
elif w=="RRS":
    print(2)
elif w=="RSR":
    print(1)
elif w=="RSS":
    print(1)
elif w=="SRS":
    print(1)
elif w=="SSR":
    print(1)
else :
    print(0)

Verdicts: Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

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

rev = 0
for ch in ws:
    if ch == 'R':
        rev += 1
    else:
        rev = 0

return rev

ws = input()

rev = 0
for ch in ws:
    if ch == 'R':
        rev += 1
    else:
        rev = 0

print(rev)

ws = input()

if ws.count('S') == 3:
    print(0)
elif ws.count('S') == 2:
    print(1)
elif ws.count('S') == 1:
    if ws.index('S') == 1:
        print(1)
    else:
        print(2)
else:
    print(3)


Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
S=input()
print(max(i for i in range(4)if S.index("R"*i)))

S = input()

if S == "SSS":
    cnt = 0
elif S == "RRR":
    cnt = 3
elif "RR" in S:
    cnt = 2
else:
    cnt = 1
    
print(cnt)

Verdicts: Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
weat= input()
seaS = 'S'
seaR = 'R'
a = 0
b = 0
c = 0
imput = 0
for alp in wea:
  if a == 0:
    if alp == seaS:
      a = 1
    if alp == seaR:
      a = 2
  if b == 0 and a != 0:
    if alp == seaS:
      b = 1
    if alp == seaR:
      b = 2
  if c == 0 and a != 0 and b != 0:
    if alp == seaS:
      c = 1
    if alp == seaR:
      c = 2
if a or b or c == 2:
  imput = 1
if a and b == 2 or b and c == 2:
  imput = 2
if a and b and c == 3:
  imput = 3

print(imput)


weat= input()
seaS = 'S'
seaR = 'R'
a = 0
b = 0
c = 0
imput = 0
for alp in weat:
  if a == 0:
    if alp == seaS:
      a = 1
    if alp == seaR:
      a = 2
  if b == 0 and a != 0:
    if alp == seaS:
      b = 1
    if alp == seaR:
      b = 2
  if c == 0 and a != 0 and b != 0:
    if alp == seaS:
      c = 1
    if alp == seaR:
      c = 2
if a or b or c == 2:
  imput = 1
if a and b == 2 or b and c == 2:
  imput = 2
if a and b and c == 2:
  imput = 3

print(imput)


weat= input()
seaS = 'S'
seaR = 'R'
a = 0
b = 0
c = 0
imput = 0
for alp in weat:
  if a == 0:
    if alp == seaS:
      a = 1
    if alp == seaR:
      a = 2
  if b == 0 and a != 0:
    if alp == seaS:
      b = 1
    if alp == seaR:
      b = 2
  if c == 0 and a != 0 and b != 0:
    if alp == seaS:
      c = 1
    if alp == seaR:
      c = 2
if a == 2 or b == 2 or c == 2:
  imput = 1
if a == 2 and b == 2 or b == 2 and c == 2:
  imput = 2
if a == 2 and b == 2 and c == 2:
  imput = 3

print(imput)

weat= input()
imput = 0
if weat == 'SSS':
  imput = 0
if weat == 'SSR' or weat == 'RSS' or weat == 'SRS' or weat == 'RSR':
  imput = 1
if weat == 'SRR' or weat == 'RRS':
  imput = 2
if weat == 'RRR':
  imput = 3

print(imput)

Verdicts: Runtime Error

Wrong Answer

Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
X, K, D = map(int, input().split())
if X == 0:
  if (K % 2 == 0):
    a = 0
  else:
    a = D
else:
  if X < 0:
    X = -X
  s = int(X/D)
  if K <= s:
    a = X - K * D
  else:
    if (K - s) % 2 == 1:
      a = abs(X - (s + 1) * D)
    else:
      a = abs(X - s * D)
print(a)

N = int(input())
L = list(map(int, input().split()))
a = 0
if N > 2:
    for i in range(N):
        for j in range(i+1, N):
            for k in range(j+1, N):
                if L[i] == L[j] or L[i] == L[k] or L[j] == L[k]:
                    continue
                if L[i] + L[j] > L[k] and L[i] + L[k] > L[j] and L[j] + L[k] > L[i]:
                    a = a + 1
print(a)

S = str(input())
a = 0
w = 0
for i in range(len(S)):
    if S[i] == 'R':
        w = w + 1
    else:
        if (w > a):
          a = w
        w = 0
if (w > a):
  a = w
print(a)

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
if s == "RRR":
  print(3)
elif s == "RRS" or s == "SRR":
  print(2)
elif s == "RSR" or s == "RSS" or s == "SSR" or s == "SRS":
  print(1)
else:
  print(0)

s = str(input())
if s == "RRR":
  print(3)
elif s == "RRS" or s == "SRR":
  print(2)
elif s == "RSR" or s == "RSS" or s == "SSR" or s == "SRS":
  print(1)
else:
  print(0)

Verdicts: Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
s=input()
ans=0
for i in s:
    if(i=='R'):
        ans+=1
    else:
        ans=0
print(ans)

s=input()
ans=0
retur=[]
for i in s:
    if(i=='R'):
        ans+=1
    else:
        ans=0
    retur.append(ans)
print(max(retur))

Verdicts: Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
S=input()
if "SSS" in S:
    print("3")
elif "SS" in S:
    print("2")
elif "S" in S:
    print("1")
else:
    print("0")

S=input()
if "RRR" in S:
    print("3")
elif "RR" in S:
    print("2")
elif "R" in S:
    print("1")
else:
    print("0")

Verdicts: Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
s = input()
if s === 'RRR':
    print(3)
elif s[:2] == 'RR' or s[1:] == 'RR':
    print(2)
elif s.count('R') >= 1:
    print(1)
else:
    print(0)

s = input()
if s=='RRS' or s=='SRR':
    print(2)
elif s=='RRR':
    print(3)
elif s=='SSS':
    print(0)
else:
    print(1)

Verdicts: Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
X, K, D = (int(x) for x in input().split())
X = abs(X)

straight = min(K, X // D)
K -= straight
X -= straight * D

if K % 2 == 0:
    print(X)
else:
    print(D-X)

S = input()
s_num = len(S)

i=0
max_count = 0
count = 0

while i < s_num:
    if S[i] != "R":
        if max_count < count:
            max_count = count
            count = 0
    elif S[i] == "R":
        count += 1

    i+=1

if max_count < count:
    max_count = count

print(max_count)

Verdicts: Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

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

counts = []
count = 1
if s.find('R') == -1:
    count = 0
else:
    for a, b in zip(s, s[1:]):
        if a == b and a == 'R':
            count += 1
        else:
            counts.append((a, count))
            count = 1

print(str(count))


s = input()

counts = []
count = 1
if s.find('R') == -1:
    count = 0
else:
    for a, b in zip(s, s[1:]):
        if a == b and a == 'R':
            count += 1
        else:
            counts.append((a, count))

print(str(count))


Verdicts: Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
a=input()
flag=False
ans=0
hold=0
for i in range(3):
    if a[i]=='R' and not flag:
        ans=1
        flag=not flag
        hold=max(hold,ans)

    elif a[i]=='R' and flag:
        ans+=1
        hold=max(hold,ans)

    else:
        ans=0
        flag=False


return(hold)


s=input()
ans=0
flag=False
for i in a:
  if i=='R' and not flag:
    ans=1
    hold=ans
    
  if i=='R' and flag:
    ans+=1
    hold=ans
    
  else:
    ans=0
    flag=False
    
  return hold
    

a=input()
flag=False
ans=0
hold=0
for i in range(3):
    if a[i]=='R' and not flag:
        ans=1
        flag=not flag
        hold=max(hold,ans)

    elif a[i]=='R' and flag:
        ans+=1
        hold=max(hold,ans)

    else:
        ans=0
        flag=False


print(hold)



Verdicts: Runtime Error

Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
max = 0
for letter in S:
    if letter == "R":
        max += 1
    if letter == "S":
        break 
print(max)

S = input()

l = len(S)
count = 0

for i in range(l):
    if "R" not in S:
        break
    cur_count = 1

    for j in range(i+1,l):
        if S[i] == "S":
            break
        if (S[i] != S[j]):
            break
        cur_count += 1
    if cur_count > count:
        count = cur_count

print(count)

Verdicts: Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
x,k,d=map(int,input().split())
if d>=x:
  print(x)
  exit()
else:
  if x//d>=k:
    print(x-k*d)
    exit()
  else:
    if (x//d)%2==k%2:
      print(x%d)
      exit()
    else:
      print(d-x%d)
      exit()

s=input()
c=0
for i in range(3):
  if s[i]=='R':
    c+=1
if s=='RSR' :
  print(1)
else:
  print(c)

Verdicts: Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

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

if S.count('R')==0:
  print(0)
if S.count('R')==1:
  print(1)
if S.count('R')==2 and not moji.count('RR') ==1:
  print(1)
if S.count('RR')==1:
  print(2)
if S.count('RRR')==1:
  print(3)
  

S=input()

if S.count('R')==0
  print(0)
if S.count('R')==1
  print(1)
if S.count('R')==2 and moji.count('RR')!=1
  print(1)
if S.count('RR')==1
  print(2)
if S.count('RRR')==1
  print(3)
  

moji=input()

if moji.count('R')==0
  print(0)
if moji.count('R')==1
  print(1)
if moji.count('R')==2 and moji.count('RR')!=1
  print(1)
if moji.count('RR')==1
  print(2)
if moji.count('RRR')==1
  print(3)
  

S=input()

if S.count('R')==0
  print(0)
if S.count('R')==1
  print(1)
if S.count('R')==2 and not moji.count('RR') ==1
  print(1)
if S.count('RR')==1
  print(2)
if S.count('RRR')==1
  print(3)
  

S=str(input())

if S.count('R')==0
  print(0)
if S.count('R')==1
  print(1)
if S.count('R')==2 and moji.count('RR')!=1
  print(1)
if S.count('RR')==1
  print(2)
if S.count('RRR')==1
  print(3)
  

S=str(input())

if S.count('R')==0
  print(0)
if S.count('R')==1
  print(1)
if S.count('R')==2 and not moji.count('RR') ==1
  print(1)
if S.count('RR')==1
  print(2)
if S.count('RRR')==1
  print(3)
  

S=str(input())
 
if S.count('R')==0:
  print(0)
if S.count('R')==1 :
  print(1)
if S.count('R')==2 and not S.count('RR') ==1:
  print(1)
if S.count('RR')==1 and not S.count('RRR')==1:
  print(2)
if S.count('RRR')==1:
  print(3)

Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
s=str(input())
ans=0
if s not in "R":
    ans=0
else:
    if s[1]=="S":
        ans=1
    elif s[0]=="R" and s[2]=="R":
        ans=3
    else:
        ans=2

print(ans)

s=str(input())
ans=0
if s[0]=="R":
    ans=1
    if s[1]=="R":
        ans=2
        if s[2]=="R":
            ans=3
else:
    if s[1]=="R":
        ans=1
        if s[2]=="R":
            ans=2
    else:
        if s[2]=="R":
            ans=1
print(ans)

Verdicts: Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
S = input()
if S = 'SSS':
  a = 0
if S = 'SSR':
  a = 1
if S = 'SRS':
  a = 1
if S = 'SRR':
  a = 2
if S = 'RSS':
  a = 1
if S = 'RSR':
  a = 1
if S = 'RRS':
  a = 2
if S = 'RRR':
  a = 3
print(a)
  

S = input()
if S == 'SSS':
  a = 0
if S == 'SSR':
  a = 1
if S == 'SRS':
  a = 1
if S == 'SRR':
  a = 2
if S == 'RSS':
  a = 1
if S == 'RSR':
  a = 1
if S == 'RRS':
  a = 2
if S == 'RRR':
  a = 3
print(a)

Verdicts: Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
s=input().strip()
arr=s.split("S")
ans=0
for i in arr:
  ans=max(ans,len(i))

s=input().strip()
arr=s.split("S")
print(max(arr))

s=I().strip()
	arr=s.split("S")
	ans=0
	for i in arr:
		ans=max(ans,len(i))
	print(ans)

s=I().strip()
arr=s.split("S")
ans=0
for i in arr:
    ans=max(ans,len(i))
print(ans)

import sys,math
from collections import deque,defaultdict
import operator as op
from functools import reduce
sys.setrecursionlimit(10**6) 

I=sys.stdin.readline

 

#
def ii():
	return int(I().strip())
def li():
	return list(map(int,I().strip().split()))
def mi():
	return map(int,I().strip().split())

def ncr(n, r):
    r = min(r, n-r)
    numer = reduce(op.mul, range(n, n-r, -1), 1)
    denom = reduce(op.mul, range(1, r+1), 1)
    return numer // denom

def gcd(x, y):
    while y:
        x, y = y, x % y
    return x





	

def main():
	s=I().strip()
	arr=s.split("S")
	ans=0
	for i in arr:
		ans=max(ans,len(i))
	print(ans)

	













	
	
	






		







		
		
	
		

	







		









if __name__ == '__main__':
	main()

Verdicts: Wrong Answer

Wrong Answer

Runtime Error

Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

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

if s[0] == S:
  if s[1] == S:
    if s[2] == S:
      print("0")
    else:
      print("1")
  if s[1] == R:
    if s[2] == S:
      print("1")
    else:
      print("2")
if s[0] == R:
  if s[1] == S:
    if s[2] == S:
      print("1")
    else:
      print("1")
  if s[1] == R:
    if s[2] == S:
      print("2")
    else:
      print("3")

s = list(input().split())

if s[0] == "S":
  if s[1] == "S":
    if s[2] == "S":
      print("0")
    else:
      print("1")
  if s[1] == "R":
    if s[2] == "S":
      print("1")
    else:
      print("2")
if s[0] == "R":
  if s[1] == "S":
    if s[2] == "S":
      print("1")
    else:
      print("1")
  if s[1] == "R":
    if s[2] == "S":
      print("2")
    else:
      print("3")


s = input()

if s[0] == "S":
  if s[1] == "S":
    if s[2] == "S":
      print("0")
    else:
      print("1")
  if s[1] == "R":
    if s[2] == "S":
      print("1")
    else:
      print("2")
if s[0] == "R":
  if s[1] == "S":
    if s[2] == "S":
      print("1")
    else:
      print("1")
  if s[1] == "R":
    if s[2] == "S":
      print("2")
    else:
      print("3")

Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
var = 'RRR'

def func(input):
  return input.count('R')

output = func(var)
print(output)


def a(line):
	cnt = 0
	for i in range(len(line)):
		if cnt < 1 and line[i] == 'R':
			cnt += 1
			continue
		if cnt >= 1 and line[i] == line[i-1] and line[i] == 'R':
			cnt += 1
			continue
	return cnt
  
a(input())

def b(line):
	cnt = 0
	for i in range(len(line)):
		if cnt < 1 and line[i] == 'R':
			cnt += 1
			continue
		if cnt >= 1 and line[i] == line[i-1] and line[i] == 'R':
			cnt += 1
			continue
	return cnt

print(b(input()))

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
weather = input()
sunny_count = 0

for i in range(3):
  if weather[i] == "S":
    sunny_count += 1
  else:
    continue
    
print(sunny_count)   

n, k = map(int, input().split())
p_list = list(map(int, input().split()))
c_list = list(map(int, input().split()))
pc_list = []
max_score = -10**9

for m in range(n):
    score = 0
    num = p_list[m] - 1
    for l in range(k):
        score += c_list[num]
        num = p_list[num] - 1
        
        if score > max_score:
            max_score = score
 
print(max_score)

s = [x for x in input()]
count = 0
max_count = 0

for i in s:
    if i == "R":
        count += 1
        if max_count < count:
            max_count = count
    else:
        count = 0
        
print(max_count)

Verdicts: Wrong Answer

Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
day = input()
count = day.count("R")
if count == 2:
    if count1 = day.count("RR"):
	    print(2)
	else:
    	print(1)
if count == 1:
    print(1)
if count == 0:
    print(0)

s = input()

if "RRR" in s:
    print("3")
elif "RR" in s:
    print("2")
elif "R" in s:
    print("1")
else:
    print("0")

Verdicts: Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
S = 'RRS'
p = 0
for i in range(len(S)):
    if S[i] != 'S':
        p =+ 1
    else:
      	p == 0
print(p)

p = 0
for i in range(len(S)):
    if S[i] != 'S':
        p =+ 1
print(p)


S = input()
p = 0
for i in range(len(S)):
    if S[i] != 'S':
        p =+ 1
print(p)

S = 'RRS'
p = 0
for i in range(len(S)):
    if S[i] != 'S':
        p =+ 1
print(p)

p = 0
for i in range(len(S)):
    if S[i] != 'S':
        p =+ 1
	else:
      	p == 0
print(p)

p = 0
q = 0
for i in range(len(S)):
    if S[i] != 'S':
        p += 1
        if p > q:
            q = p
    else:
      	p = 0
print(q)





S = input()
p = 0
q = 0
for i in range(len(S)):
    if S[i] != 'S':
        p += 1
        if p > q:
            q = p
    else:
      	p = 0
print(q)


Verdicts: Wrong Answer

Runtime Error

Wrong Answer

Wrong Answer

Runtime Error

Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
sr_list = list(input().split())
r_count = sr_list.count('R')
if r_count == 0:
  print('0')
elif r_count == 1:
  print('1')
elif r_count ==3:
  print('3')
else:
  if sr_list[1] == 'S':
    print('1')
  else:
    print('2')

sr_list = list(input())
r_count = sr_list.count('R')
if r_count == 0:
  print('0')
elif r_count == 1:
  print('1')
elif r_count ==3:
  print('3')
else:
  if sr_list[1] == 'S':
    print('1')
  else:
    print('2')

Verdicts: Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
x,k,d=map(int,input().split())
x=abs(x)

semin=x//d 
if semin%2==0:
  minb=0 が偶数
else:
  minb=1 が奇数

if semin>k:
  print(abs(x-k*d))
else:
  k=k-semin
  if k%2==0:
    ans=0 
  else:
    ans=1 
  if ans==0:
    if minb==0:
      print(abs(x-d*semin))
    else:
      print(min(abs((x-(d*semin))-d),abs(x-d*semin)))
  else:
    if minb==0:
      print(abs((x-(d*semin))-d))
    else:
      print(abs(x-d*semin))  

s=input()
ans=0

for i in range(1,4):
  r="R"*i
  if r in s:
    ans=i
print(ans)

Verdicts: Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

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

A=0
for i in range(3):
  if a[i]=='R':
    A+=1
  else: A=0
  
print(A)

a = input()

if a =='RRR':
  print(3)
elif 'RR' in a: 
  print(2)
elif 'R' in a: 
  print(1)

else: print(0)



Verdicts: Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
s = input().rstrip()
if "SSS" in s:
    print(3)
elif "SS" in s:
    print(2)
elif "S" in s:
    print(1)
else:
    print(0)

s = input().rstrip()
if "RRR" in s:
    print(3)
elif "RR" in s:
    print(2)
elif "R" in s:
    print(1)
else:
    print(0)

Verdicts: Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
n,k=map(int,input().rstrip().split())
p=list(map(int,input().rstrip().split()))
c=list(map(int,input().rstrip().split()))
def find(start,now,up,max,sum,count,flag):
    if start==now:
        flag+=1
    if start==now and flag==2:
        return [max,sum,count]
    elif count==up:
        return [max,sum,count]
    else:
        count+=1
        sum+=c[p[now-1]-1]
        if max<=sum:
            max=sum
        return find(start,p[now-1],up,max,sum,count,flag)
kara=[]
if n>k:
    for i in range(1,n+1):
        kara.append(find(i,i,k,c[p[i-1]-1],0,0,0)[0])
    result=max(kara)
else:
    for i in range(1,n+1):
        m=find(i,i,n,c[p[i-1]-1],0,0,0)
        if m[1]<=0:
            kara.append(m[0])
        else:
            w=k%m[2]
            spe=find(i,i,w,c[p[i-1]-1],0,0,0)[0]
            if w==0:
                spe=0
            if m[0]>int(m[1]*(k-w)//m[2]+spe):
                kara.append(m[0])
            else:
                kara.append(int(m[1]*(k-w)//m[2]+spe))
    result=max(kara)
print(result)


main=input().rstrip()
count=0
flag=0
for i in range(3):
    if main[i]=='R' and flag==0:
        count+=1
    elif main[i]=='R' and flag==1:
        count=0
        count+=1
        flag=0
    else:
        flag=1
print(count)


Verdicts: Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
S=list(input())
ans=0

for i in range(len(S)):
    if ans=0 and S[i]="R":
        ans=1
for i in range(len(S)-1):
    if S[i]=="R" and S[i+1]=="R":
        ans+=1

print(ans)



S=list(input())
ans=0
for i in range(len(S)-1):
    if S[i]=="R" and S[i+1]=="R":
        ans+=1

print(ans)



Slist=list(input())
ans=0

for i in range(len(S)):
    if ans=0 and S[i]="R":
        ans=1
for i in range(len(S)-1):
    if S[i]=="R" and S[i+1]=="R":
        ans+=1

print(ans)



S=list(input())
ans=0

for i in range(len(S)):
    if ans==0 and S[i]=="R":
        ans=1
for i in range(len(S)-1):
    if S[i]=="R" and S[i+1]=="R":
        ans+=1

print(ans)



Verdicts: Runtime Error

Wrong Answer

Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
a = input()
total = 0
for i in a[range(1,4)]:
  if i = R:
    total +=1
  else:
    total = 0

a = input()
total = 0
for i in a[range(1,4)]:
  if i = 'R':
    total +=1
  else:
    total = 0


a = input()
if a =='SSS':
  print(0)
elif a=='RSS' or'SRS'or 'SSR'or 'RSR':
  print(1)
elif a == 'RRS'or 'SRR':
  print(2)
else:
  print(3)

a = input()
if a =='SSS':
  print(0)
elif a=='RRR':
  print(3)
elif a == 'RRS' or a== 'SRR':
  print(2)
else:
  print(1)


Verdicts: Runtime Error

Runtime Error

Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

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

if "SSS" in S:
  print(3)
elif "SS" in S:
  print(2)
elif "S" in S:
  print(1)
else:
  print(0)

S = input()
ren = 0

if "RRR" in S:
  print(3)
elif "RR" in S:
  print(2)
elif "R" in S:
  print(1)
else:
  print(0)

Verdicts: Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

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

day1 = days[0]
day2 = days[1]
day3 = days[2]


ans = 0

if day1 == "R":
    ans += 1
    if day2 == "R":
        ans += 1
        if day3 == "R":
            ans +=1
 
if day2 == "R":
    ans += 1
    if day3 == "R":
         ans +=1

if day3 == "R":
    ans +=1

print(ans)

days = input()

day1 = days[0]
day2 = days[1]
day3 = days[2]

ans = 0

if day1 == "R":
    ans += 1
    if day2 == "R":
        ans += 1
        if day3 == "R":
            ans +=1
elif day2 == "R":
    ans += 1
    if day3 == "R":
         ans +=1

elif day3 == "R":
    ans +=1

print(ans)

Verdicts: Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

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

if S[0] == 'S':
  if S[1] == 'S':
    if S[2] == 'S':
      print(3)
    else:
      print(2)
  else:
    print(1)
elif S[1] == 'S':
  if S[2] == 'S':
    print(2)
  else:
    print(1)
elif S[1] == 'R':
  print(0)
  if S[2] == 'S':
    print(1)

S = input()

a = (S[0] == 'S')
b = (S[1] == 'S')
c = (S[2] == 'S')

if a and b and c:
  print(3)
elif (a and b and (c == False)) or ((a == False) and b and c):
  print(2)
elif (a == False) and (b == False) and (c == False):
  print(0)
else:
  print(1)

S = input()
 
a = (S[0] == 'R')
b = (S[1] == 'R')
c = (S[2] == 'R')
 
if a and b and c:
  print(3)
elif (a and b and (c == False)) or ((a == False) and b and c):
  print(2)
elif (a == False) and (b == False) and (c == False):
  print(0)
else:
  print(1)

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
N, X, T = map(int, input().split())
y = N // X
c = N % X
print((y * T + T) if c else (y * T))

s=input()
for i in range(4)[::-1]:
    if "R"*i in s:
        print(i)
        break

Verdicts: Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
X, K, D = map(int, input().split())
X_a = abs(X)
if X_a - K * D > D:
    print(X_a - K * D)
else:
    K -= X_a // D
    X_a = X_a % D
    while X_a >= D:
        X_a -= D
        K -= 1
    if  K % 2 == 0:
        print(X_a)
    else:
        print(abs(X_a-D))

S = input()
if S == 'SSS':
    print(0)
elif S == 'RRR':
    print(3)
elif S == 'RRS' or S == 'SRR':
    print(2)
else:
    print(1)

Verdicts: Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
s=input()
if s=='RRR':
  print(3)
elif s=='SSS':
  print(0)
elif (s=='SRR' or s=='RRS'):
  prinr(2)
else:
  print(1)

s=input()
if s=='RRR':
  print(3)
elif s=='SSS':
  print(0)
elif (s=='SRR' or s=='RRS'):
  print(2)
else:
  print(1)


Verdicts: Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
S = input()
if S.contains("RRR"):
    print("3")
elif S.contains("RR"):
    print("2")
elif S.contains("R"):
    print("1")
else:
    print("0")

days = input()
if days.contains("RRR"):
    print("3")
elif days.contains("RR"):
    print("2")
elif days.contains("R"):
    print("1")
else:
    print("0")

s = input().upper()
if s.count('RRR') == 1:
  print(3)
elif s.count('RR') == 1:
  print(2)
elif s.count('R') > 0:
  print(1)
else:
  print(0)
  

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

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

if S.count("RRR") <= 1:
  print("3")
elif S.count("RR") <= 1:
  print("2")
elif S.count("R") <= 1:
  print("1")
else:
  print("0")

S = input()

if S.count("RRR") >= 1:
  print("3")
elif S.count("RR") >= 1:
  print("2")
elif S.count("R") >= 1:
  print("1")
else:
  print("0")

Verdicts: Wrong Answer

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

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

if S == "RRR":
    print(3)
elif S == "SSS":
    print(0)
elif S[0:2] == "R" or S[1:3] == "R":
    print(2)
else:
    print(1)

S = input()

if S == "RRR":
    print(3)
elif S[0,1] == "R" or S[1,2] == "R":
    print(2)
elif S[0,1] == "S" or S[1,2] == "S":
    print(1)
else:
    print(0)


S = input()

if S == "RRR":
    print(3)
elif S == "SSS":
    print(0)
elif S[0:2] == "RR" or S[1:3] == "RR":
    print(2)
else:
    print(1) 

Verdicts: Wrong Answer

Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
temp = str(input())
count = 0

for i in temp:
  if i == R:
    count = count + 1
  else:
    count = 0
    
print(count)

temp = str(input())
count = 0
max_count = 0 

for i in temp:
  if i == 'R':
    count = count + 1
    max_count = count
  else:
    if max_count < count:
      max_count = count
    count = 0
    
print(max_count)

Verdicts: Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
S = input()
x = 0
if S == 'RSR':
    print(1)
else:
    for i in S:
        if i == 'R':
            x += 1
    print(a)

str = input()
if str == "RRR":
    print(3)
elif str == "SSS":
    print(0)
elif str == "RRS":
    print(2)
elif str == "SRS":
    print(1)
elif str == "SRR":
    print(2)
elif str == "RSR":
    print(1)
elif str == "RSS":
    print(1)
elif str == "SSR":
    print(1)
`

S = input()
x = 0
if S == 'RSR':
    print(1)
else:
    for i in S:
        if i == 'R':
            x += 1
    print(x)

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
a = input()
if s == "SSS":
    print(0)
elif s == "SSR":
    print(1)
elif s == "SRS":
    print(1)
elif s == "SRR":
    print(2)
elif s == "RSS":
    print(1)
elif s == "RSR":
    print(1)
elif s == "RRS":
    print(2)
elif s == "RRR":
    print(3)

        

a = input()
b = 0
if s == "SSS":
    print(0)
elif s == "SSR":
    print(1)
elif s == "SRS":
    print(1)
elif s == "SRR":
    print(2)
elif s == "RSS":
    print(1)
elif s == "RSR":
    print(1)
elif s == "RRS":
    print(2)
elif s == "RRR":
    print(3)

        

s = input()
if s == "SSS":
    print(0)
elif s == "SSR":
    print(1)
elif s == "SRS":
    print(1)
elif s == "SRR":
    print(2)
elif s == "RSS":
    print(1)
elif s == "RSR":
    print(1)
elif s == "RRS":
    print(2)
elif s == "RRR":
    print(3)

        

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
s = input()
if s == 'RRR':
  print(3)
elif s=='RSR' or 'SRS' or 'SSR' or 'RSS':
  print(1)
elif s == 'RRS' or 'SRR':
  print(2)
else:
  print(0)

N = int(input())
A = list(map(int,input().split()))
A.sort()
cnt = 0
for i in range(0,N):
  for j in range(i+1,N):
    for k in range(j+1,N):
      if (A[i]!=A[k]!=A[j]):
        if (A[i]+A[j])>A[k]:
          cnt+=1
        
print(cnt)

s = input()
if s == 'RRR':
  print(3)
elif s=='RSR' or s=='SRS' or s=='SSR' or s=='RSS':
  print(1)
elif s == s=='RRS' or s=='SRR':
  print(2)
else:
  print(0)

Verdicts: Wrong Answer

Runtime Error

Accepted
Problem: We have weather records at AtCoder Town for some consecutive three days. A string of length 3, S, represents the records - if the i-th character is `S`, it means it was sunny on the i-th day; if that character is `R`, it means it was rainy on that day.  Find the maximum number of consecutive rainy days in this period.

Submission attempts (in order):
a = input()
s = 0
if a == "RRR":
  s = 3
elif a == "RRS" or a == "SRR":
  s = 2
elif a = "SSS":
  s = 0
else:
  s = 1
print(s)

a = input()
s = 0
if a == "RRR":
  s = 3
elif a == "RRS" or a == "SRR":
  s = 2
elif a == "SSS":
  s = 0
else:
  s = 1
print(s)

Verdicts: Runtime Error

Accepted