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):
s=input()
c=0
for i in range(3):
  if s[i] == 'R':
    c+=1
  else:
    c=0
print(c)

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):
D, T, S = map(int,input().split())
if S * T >= D: print("Yes")
else: print("No")

S = input()
count = 0
ans = 0
for i in range(3):
  if S[i] == "R":
    count += 1
    ans = max(ans, count)
  else:
    ans = max(ans, count)
    count = 0


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):
def count_rainy(weather): 
    return len([r for r in weather if r == 'R'])

weather = input()
if len(weather) == 3:
    for w in weather:
        if w == 'S' or w == 'R':
            print(count_rainy(weather))

def count_rainy(weather):
    return len([r for r in weather if r == 'R'])

def count_rainy(weather): 
    return len([r for r in weather if r == 'R'])

weather = 'SSR'
print(count_rainy(weather))

def count_rainy(weather):
    return len([r for r in weather if r == 'R'])

weather = 'SSR'
count_rainy(weather)

def count_rainy(weather): 
    if weather == 'RSR':
        return 1
    return len([r for r in weather if r == 'R'])

weather = input()
print(count_rainy(weather))

Verdicts: Wrong Answer

Wrong Answer

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):
Q =input()
if Q.count(R)==3:
    print(3)
elif Q.count(R)==0:
    print(0)
elif Q.count(R)==1:
    print(1)
elif Q.count(R)==2:
    if Q.[2] =='S'
    print(1)
    else :
        print(2)

S =input()
print(S.count(R))

x,k,d = map(int,input().split())
y = abs(x)//d
if y >= k:
        ans = abs(abs(x)-d*k)

else:
        if (k-y)% 2 == 0:
                ans = abs(abs(x)-d*y)
        else:
                ans = min(abs(abs(x)-d*y+d),abs(abs(x)-d*y-d))
print(ans)

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

Verdicts: 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):
Word=input()
Word_list=list(Word)

number=0
renzoku=0

for num in range(3):
  if Word_list[num]="R":
    number=number+1
  else:
    if(number>renzoku):
      renzoku=number
    number=0

Word=input()
Word_list=list(Word)
 
number=0
renzoku=0
Enter=0
 
for num in range(3):
  if Word_list[num]=="R":
    number=number+1
  if (number>renzoku):
      renzoku=number
  else:
    number=0

print(renzoku)

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.count("S")==0:
    print(0)
elif s.count("S")==1:
    print(1)
elif s.count("S")==3:
    print(3)
else:
    if s[1]=="S":
        print(2)
    else:
        print(1)

s=input()
if s.count("R")==0:
    print(0)
elif s.count("R")==1:
    print(1)
elif s.count("R")==3:
    print(3)
else:
    if s[1]=="R":
        print(2)
    else:
        print(1)

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):
import heapq

N, K = map(int, input().split(" "))
 
Ps = list(map(int, input().split(" ")))
Cs = list(map(int, input().split(" ")))


max_points = []
heapq.heapify(max_points)
for now_point in range(2, N+1):
    max_point = -float('inf')
    C_point = 0
    max_point = []
    heapq.heapify(max_point)
    for _ in range(K):
        next_point = Ps[now_point-1]
        C_point += Cs[next_point-1]
        
        heapq.heappush(max_point, -C_point)
        now_point = next_point
    
    max_point_ = heapq.heappop(max_point)
    heapq.heappush(max_points, max_point_)
 
print(-heapq.heappop(max_points))

import heapq

N, K = map(int, input().split(" "))
 
Ps = list(map(int, input().split(" ")))
Cs = list(map(int, input().split(" ")))


max_points = []
heapq.heapify(max_points)
for start_point in range(1, N+1):
    flg = False
    C_point = 0
    max_point = []
    heapq.heapify(max_point)
    now_point = start_point
    for _ in range(K):
        next_point = Ps[now_point-1]
        C_point += Cs[next_point-1]
        
        heapq.heappush(max_point, -C_point)
#        max_point.append(C_point)
        now_point = next_point
    
        if next_point == start_point:
            flg = True
            l = _ + 1
            last_point = C_point
            break
        
    if flg:
#        print("l",l)
        q, r = divmod(K, l)
#        print(q,r)
        now_point = start_point
        C_point = 0
        for _ in range(r):
            next_point = Ps[now_point-1]
            C_point += Cs[next_point-1]
            ins = last_point * q + C_point
            heapq.heappush(max_point, -ins)
#            max_point.append(ins)
            
            now_point = next_point        
#    print("2nd", max_point)
    max_point_ = heapq.heappop(max_point)
    heapq.heappush(max_points, max_point_)
#    max_points.append(max(max_point))
    
print(-heapq.heappop(max_points))
#print(max(max_points))

import re

S = input()

rrr = S.count("RRR")
rr = S.count("RR")
r = S.count("R")

if rrr == 1:
    print(3)
elif rr == 1:
    print(2)
elif r == 1 or r == 2:
    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):
if __name__ == "__main__":
    S = input()
    rains = 0
    for i, s in enumerate(S):
        if s == 'R':
            rains += 1
        else:
            rains = 0

    print(rains)



if __name__ == "__main__":
    S = input()
    list_s = [s for s in S]
    ans = 0
    if list_s[0] == 'S' and list_s[1] == 'S' and list_s[2] == 'S':
        ans = 0
    elif list_s[0] == 'S' and list_s[1] == 'S' and list_s[2] == 'R':
        ans = 1
    elif list_s[0] == 'S' and list_s[1] == 'R' and list_s[2] == 'R':
        ans = 2
    elif list_s[0] == 'R' and list_s[1] == 'R' and list_s[2] == 'R':
        ans = 3
    elif list_s[0] == 'R' and list_s[1] == 'S' and list_s[2] == 'R':
        ans = 1
    elif list_s[0] == 'R' and list_s[1] == 'R' and list_s[2] == 'S':
        ans = 2
    elif list_s[0] == 'R' and list_s[1] == 'S' and list_s[2] == 'S':
        ans = 1
    elif list_s[0] == 'S' and list_s[1] == 'R' and list_s[2] == 'S':
        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):
a = input()

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

a = input()

if 'RRR' in a:
  print(3)
elif 'RR' in a:
  print(2)
elif 'R' in a:
  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() + '@'

lst = [0]*len(s)
for i in range(1,len(s)):
  if s[i] == s[i-1]:
    lst[i] = lst[i-1] + 1
print(max(lst))

s = input() + '@'

lst = [1]*len(s)
for i in range(1,len(s)):
  if s[i] == s[i-1]:
    lst[i] = lst[i-1] + 1

ans = 0
for i in range(0,len(s)):
	if s[i] == 'R':
		ans = max(ans,lst[i])

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()
res = 0

if s[0] == s[1]:
  res += 1
if s[1] == s[2]:
  res += 1

print(res)
  

s = input()
res = 0
 
if s[0] == s[1]:
  res += 1
if s[1] == s[2]:
  res += 1
 
print(res)
  

s = input()
res = 1
 
if s[0] == "R" and s[1] == "R":
  res += 1
if s[1] == "R" and s[2] == "R":
  res += 1
  
if "R" in s:
  print(res)
else:
  print(0)

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 = str(input())
if S == "SSS":
    print(0)
elif S == "SSR"or"SRS"or"RSS"or"RSR":
    print(1)
elif S == "SRR"or"RRS":
    print(2)
elif S == "RRR":
    print(4)

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

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

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

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

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

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

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

S = input()
r = S.count("R")
if r == 0:
    print(0)
elif r == 1:
    print(1)
elif r == 3:
    print(3)
elif r == 2:
    if S == "RSR":
        print(1)
    else:
        print(2)

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Wrong Answer

Wrong Answer

Wrong Answer

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):
str =list(input())
counter =0
max=0
for s in str:
    if s ='S':
        counter =0
    else 
       counter +=1
       if max <counter
          max =counter
print(max)

str =list(input())
counter =0
max=0
for s in str:
    if s =='S':
        counter =0
    else :
       counter +=1
       if max <counter:
          max =counter
print(max)

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()
flg = 0
cnt = 0
if s[1] == "S":
    flg = 1
for i in range(3):
    if s[i] == "S":
        cnt += 1
print(cnt if flg == 1 else cnt -1)

s=input()
flg = 0
cnt = 0
if s == "SSS":
    print(0)
    exit()
if s[1] == "S":
    flg = 1
for i in range(3):
    if s[i] == "R":
        cnt += 1
if cnt >= 2 and flg == 1:
    print(cnt -1)
else:
    print(cnt)

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):
import sys
def input(): return sys.stdin.readline().rstrip()
def ii(): return int(input())
def mi(): return map(int, input().split())
def li(): return list(mi())


def main():
    s = input()
    cnt = 0
    for i in range(1, 3):
        if s[i] == 'R' and s[i-1] == 'R':
            cnt += 1
    print(cnt)


if __name__ == '__main__':
    main()

import sys
def input(): return sys.stdin.readline().rstrip()
def ii(): return int(input())
def mi(): return map(int, input().split())
def li(): return list(mi())


def main():
    s = input()
    cnt = 0
    if 'RRR' in s:
        print(3)
    elif 'RR' in s:
        print(2)
    elif 'R' in s:
        print(1)
    else:
        print(0)


if __name__ == '__main__':
    main()

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

m = 0
cnt = 0
for i in range(3):
    if s[i] == 'r':
        cnt += 1
    else:
        m = max(m, cnt)
        cnt = 0

print(max(m, cnt))

s = input()

m = 0
cnt = 0
for i in range(3):
    if s[i] == 'R':
        cnt += 1
    else:
        m = max(m, cnt)
        cnt = 0

print(max(m, cnt))

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()
if A == RRR
	print("3")
elif A == SSS
	print("0")
elif A == RRS
	print("2")
elif A == SRR
	print("2")
else 
	print("1")


print(input().count("S"))

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

if S == RRR
	print("3")
elif S == SSS
	print("0")
elif S == RRS
	print("2")
elif S == SRR
	print("2")
else 
	print("1")


s = input().split()
if s[0] == R and s[1] == R and s[2] == R 
	print("3")
elif s[0] == S and s[1] == S and s[2] == S 
	print("0")
elif s[0] == R and s[1] == R and s[2] == S 
	print("2")
elif s[0] == S and s[1] == R and s[2] == R
	print("2")
else 
	print("1")


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



Verdicts: Runtime Error

Wrong Answer

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 = input()
if S = 'SSS':
  print('0')
elif S = 'RRR':
  print('3')
elif S = 'RRS' or S = 'SRR':
  print('2')
else :
  print('1')
  

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):
x, k, d = map(int, input().split())
if k%2 == 0 and abs(x)==abs(d):
  print(abs(x))
  exit()

for i in range(k):
  if abs(x - d) <= abs(x + d):
      x = x - d
  else:
      x = x + d
print(abs(x))



s = input()
iter = 0
if s[0] =="R"and s[1]=="R" and s[2]=="R":
  print(3)
elif s[0] =="R"and s[1]=="R":
  print(2)
elif s[1]=="R" and s[2]=="R":
  print(2)
elif s[0] =="R"or s[1]=="R" or s[2]=="R":
  print(1)
elif s[0] =="R"and s[2]=="R":
  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):
# rainy season

def rainy(S):
  if 'SSS' in S:
    return 3
  if 'SS' in S:
    return 2
  if 'S' in S:
    return 1
  return 0

if __name__ == "__main__":
  input = list(input().split())
  print(rainy(input[0]))


# rainy season

def rainy(S):
  if 'RRR' in S:
    return 3
  if 'RR' in S:
    return 2
  if 'R' in S:
    return 1
  return 0

if __name__ == "__main__":
  input = list(input().split())
  print(rainy(input[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()

if a == "RRR":
  answer=2
elif a=="RRS" or a=="SRR":
  answer=1
else:
  answer=0
  
print(answer)

a=input()

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

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 sys import stdin,stdout
from collections import defaultdict
import math
#input=stdin.readline
#def print(x):stdout.write(str(x)+'\n')
for _ in range(int(input())):
    s=input()
    if s=='RRR':
        print(3)
    elif 'RR' in s:
        print(2)
    elif 'R' in s:
        print(1)
    else:
        print(0)

from sys import stdin,stdout
from collections import defaultdict
import math
#input=stdin.readline
#def print(x):stdout.write(str(x)+'\n')
s=input()
if s=='RRR':
    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):
MOD = 1000000007
from collections import defaultdict as dd,Counter,deque

def si(): return input()
def ii(): return int(input())
def li(): return list(map(int,input().split()))
def mi(): return map(int,input().split())
def out(v): print(v)
def spout(): print(v,end=" ")
def d2b(n): return bin(n).replace("0b","")
def twod(n,m,num):return [[num for x in range(m)] for y in range(n)]
def vow(): return ['a','e','i','o','u']
def let(): return [chr(i) for i in range(97,123)]
def gcd(x, y):
    while y:
        x, y = y, x % y
    return x
def ispow2(x):
    return (x and (not(x & (x - 1))))
def prime_factors(n):
    i = 2
    factors = []
    while i * i <= n:
        if n % i: i+=1
        else:
            n //= i
            factors.append(i)
    if n > 1: factors.append(n)
    return (list(factors))
  
s=si()
for i in range(3):
  if s[i]=="S":
    c+=1
if c<2 or c==3: print(c)
else:
  if s[1]=="S": print(2)
  else: print(1)

s=input()
c=0
for i in range(3):
  if s[i]=="R":
    c+=1
if c<2 or c==3: print(c)
else:
  if s[1]=="R": 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):
def main():
    s = input()
    c = 0
    if s[0] == s[1] == s[2] == "R":
            print(3)
        return
    if s[0] == s[1] == "R" or s[1] == s[2] == "R":
        print(2)
        return
    if s[0] == s[1] == s[2] == "S":
        print(0)
        return

    print(1)
    return

main()



def main():
    s = input()
    c = 0
    if s[0] == s[1] == s[2] == "R":
        print(3)
        return
    if s[0] == s[1] == "R" or s[1] == s[2] == "R":
        print(2)
        return
    if s[0] == s[1] == s[2] == "S":
        print(0)
        return

    print(1)
    return

main()



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 == "SSS":
    print(0)
elif s == "RSS" or "SRS" or "SSR" or "RSR":
    print(1)
elif s == "RRS" or "SRR":
    print(2)
elif s == "RRR":
    print(3)


s = input()


    #print(0)
#elif s == "RSS" or "SRS" or "SSR" or "RSR":
    #print(1)
#elif s == 'RRS' or 'SRR':
    #print(2)

    #print(3)

if s.count("R") == 0:
    print(0)
elif s.count("R") == 1 or s == "RSR":
    print(1)
elif s.count("R") == 2:
    print(2)
elif s.count("R") == 3:
    print(3)


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 = list(input())

if "S" in S:
    if S[1] == "S" and (S[0] != "S" or S[2] != "S"):
        print(1)
    elif S[0] == "S" and S[1] == "S" and S[2] == "S":
        print(0)
    elif S[1] == "R" and (S[0] != "R" or S[2] != "R"):
        print(1)
    else:
        print(2)
else:
    print(3)

S = list(input())

if "S" in S:
    if S[1] == "S" and (S[0] != "S" or S[2] != "S"):
        print(1)
    elif S[0] == "S" and S[1] == "S" and S[2] == "S":
        print(0)
    elif S[1] == "R" and S[0] != "R" and S[2] != "R":
        print(1)
    else:
        print(2)
else:
    print(3)

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 = list(input())
RD = S.count('R')
if RD != 2:
    print(RD)
else:
    if S[1] == 'R':
        print(RD and 'bbb')
    else:
        print(1)


S = list(input())
RD = S.count('R')
if RD != 2:
    print(RD)
else:
    if S[1] == 'R':
        print(RD and 'bbb')
    else:
        print(1)


S = list(input())
RD = S.count('R')
if RD != 2:
    print(RD)
else:
    if S[1] == 'R':
        print(RD)
    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):
S = input()
 

# RRR RRS SRR RSR RSS SRS SSR SSS
ans = 0
if S == 'RRR': ans = 3
elif S == 'SRR' and S == 'RRS': ans = 2
elif S == 'SSS': ans = 0
else: ans = 1
  
print(ans)

RSR SSR SRS RSS 

S = input()

ans = 0
if S ='RRR': ans = 3
else:
  if ('RR' in S) ans = 2
  else:
    if('R' in S) ans = 1
    else: ans = 0
    
print(ans)

N = int(input())
L = list(map(int, input().split()))
 
ans = 0
if(N >= 3):
  t = []
  for i in range(N):
    for j in range(i+1, N):
      for k in range(j+1, N):
        if((abs(L[j]-L[k]) < L[i]) & (L[i] < L[j]+L[k])): t.append((L[i], L[j], L[k]))
  ans = len(set(t))

print(ans)

S = input()
 
ans = 0
if S == 'RRR': ans = 3
else:
  if ('RR' in S) ans = 2
  else:
    if('R' in S) ans = 1
    else: ans = 0

print(ans)

N = int(input())
L = list(map(int, input().split()))
 
ans = 0
for i in range(N):
  for j in range(i+1, N):
    for k in range(j+1, N):
      if(L[i] != L[j] and L[i] != L[k] and L[j] != L[k] and abs(L[j]-L[k]) < L[i] and L[i] < L[j]+L[k]):
          ans +=1
          
print(ans)

S = input()
 
ans = 0
if S ='RRR': ans = 3
else:
  if ('RR' in S) ans = 2
  else:
    if('R' in S) ans = 1
    else: ans = 0

print(ans)

S = input()
 

# RRR RRS SRR RSR RSS SRS SSR SSS
ans = 0
if S == 'RRR': ans = 3
elif S == 'SRR' and S == 'RRS': ans = 2
elif S == 'SSS': ans = 0
else: ans = 1
  
print(ans)

S = input()


ans = 0
if S == 'RRR': ans = 3
elif S == 'SRR' and S =='RSR' and S == 'RRS': ans = 2
elif S == 'SSS': ans = 0
else: ans = 1
  
print(ans)

S = input()
 

# RRR RRS SRR RSR RSS SRS SSR SSS
ans = 0
if S == 'RRR': ans = 3
elif S == 'SRR' or S == 'RRS': ans = 2
elif S == 'SSS': ans = 0
else: ans = 1
  
print(ans)

Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

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):
s=input()
if(s=='RRR'):
  print(3)
if('RR' in s):
  print(2)
if('R' in s):
  print(1)
else:
  print(0)

s=input()
if s=='RRR':
  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 = str(input())

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

S = str(input())

if S == "SSS":
    print(3)
elif S == "RSS" or S == "SSR":
    print(2)
else:
    print(1)

S = str(input())

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

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()
if "rrr" in S:
    print(3)
elif "rr" in S:
    print(2)
elif "r" 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=str(input())
if S[1]=="R":
  if S[2]=="R" and S[0]=="R":
    print(3)
  else:
    if S[0]=="R":
      print(2)
    if S[2]=="R":
      print(2)
    else:
      print(1)
else:
  if S[2]=="R" or S[0]=="R":
    print(1)
  else:
    print(0)

S=str(input())
if S[1]=="R":
  if S[2]=="R" and S[0]=="R":
    print(3)
  else:
    if S[0]=="R":
      print(2)
    elif S[2]=="R":
      print(2)
    else:
      print(1)
else:
  if S[2]=="R" or S[0]=="R":
    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()
c = 0
ans = 0
for i in range(3):
  if S[i] == 'R':
    c++
  else:
    ans = max(c,ans)
print(ans)

S = input()
c = 0
ans = 0
for i in range(3):
  if S[i] == 'R':
    c+=1
  else:
    ans = max(c,ans)
    c = 0
ans = max(c,ans)
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):
s=input()

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


s=input()

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


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()
s=s.trim()
if s=="rrs" || s=="srr":
    print("2")
else if s=="rrr":
    print("3")
else if s=="sss":
    print('0')
else:
    print('1')




s=input()
s=s.trim()
if s=="rrs" or s=="srr":
    print("2")
elif s=="rrr":
    print("3")
elif s=="sss":
    print('0')
else:
    print('1')


s = str(input())

if s.find('rr') != -1:
    print("2")
elif s.find('r') !=-1:
    print("1")
else :
    print ("0")


s = str(input())
if s == "rrs" or s == "srr":
    print('2')
elif s == "rrr":
    print('3')
elif s == "sss":
    print('0')
else:
    print('1')


s = str(input())
s=s.lower(s)

if s.find('rr') != -1:
    print("2")
elif s.find('r') !=-1:
    print("1")
else :
    print ("0")


s = str(input())
s=s.lower()

if s=="rrr":
    print('3')
elif s.find('rr') != -1:
    print("2")
elif s.find('r') != -1:
    print("1")
else:
    print ("0")


Verdicts: Runtime Error

Runtime Error

Wrong Answer

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):
def abc175_a():
    s = input()
    cnt = 0
    
    for i in range(len(s)):
        if s[i] == 'R':
            cnt += 1
        elif (i > 0) and (s[i - 1] == 'S') and (s[i] == 'R'):
            cnt = 1
        else:
            cnt = 0
    
    print(cnt)

if __name__ == '__main__':
    abc175_a()

def abc175_a_1():
    def solve():
        
        if s.count('RRR'):
            return 3
        if s.count('RR'):
            return 2
        if s.count('R'):
            return 1
        return 0

    s = input()
    print(solve())

if __name__ == '__main__':
    abc175_a_1()

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):
st = input()
if st[0] == st[1] and st[0] == st[2] and st[0] == "R":
  print(3)
elif (st[0] == st[1] == "R") OR (st[1] == st[2] == "R"):
  print(2)
else:
  print(1)

st = input()
if st[0] == st[1] and st[0] == st[2] and st[0] == "R":
  print(3)
elif (st[0] == st[1] and st[0] == "R") or (st[1] == st[2] and st[1] == "R"):
  print(2)
elif "R" in st:
  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()

if s == 'R':
  print(3)
elif s[:3] == "RR" or s[1:] == "RR":
  print(2)
elif 'R' in s:
  print(1)
else:
  print(0)

s = input()

if s == 'RRR':
  print(3)
elif s[:2] == "RR" or s[1:] == "RR":
  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()
for si in S:
    renzoku = 0
    if si == 'R':
        renzoku += 1
    else:
        renzoku = 0
print(renzoku)

S = input()
if S == 'RSR':
    renzoku = 2
else:
    for si in S:
        if si == 'R':
            renzoku += 1

print(renzoku)

S = input()
if S == 'RSR':
    renzoku = 1
else:
    renzoku = 0
    for si in S:
        if si == 'R':
            renzoku += 1

print(renzoku)

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):
S = input('').split()

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

S = input('').split()

if 'RRR' in S:
    print(3)
elif 'RR' in S:
    print(2)
elif 'R' 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

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=list(input().split())
a="".join(a)
count=0
for i in range(3):
    
    if a[i]=='S':
        count=1
    else:
        count+=1
print(count)

a=list(input().split())
a="".join(a)
count=0
for i in range(3):
    
    if a[i]=='R':
        count+=1
        ans=count
    else:
        count=0
       
        
print(count)

n=input()
n="".join(n)
c,ans=0,0
for i in range(3):
    if n[i]=="R":
        c+=1
        ans=c
    else:
        c=0
        
print(ans)

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):
S = input()
count = 0
if S[0] == 'R':
  if S[1] == 'R':
    if S[2] == 'R':
      	print(3)
  	else:
    	print(2)
  else:
    if S[2] == 'R':
      print(1)
else:
  if S[1] == 'R':
    if S[2] == 'R':
      print(2)
    else:
      print(1)
  else:
    if S[2] == 'R':
      print(1)
    else:
      print(0)

S = input()
if S[0] == 'R':
    if S[1] == 'R':
        if S[2] == 'R':
            print(3)
        else:
            print(2)
    else:
        print(1)
else:
    if S[1] == 'R':
        if S[2] == 'R':
              print(2)
        else:
              print(1)
    else:
        if S[2] == 'R':
              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):
A = input("晴れならs,雨ならrを入力してください")
if A == "sss":
	print(0)
elif A == "rrr":
  print(3)  
elif A ==  "srr" or A == "rrs":
  print(2)
else:
  print(1)

A = input("")
if A == "sss":
	print(0)
elif A == "rrr":
  print(3)  
elif A ==  "srr" or A == "rrs":
  print(2)
elif A == "rss" or A == "srs" or A == "ssr" or A == "rsr":
  print(1)

A = input()
if A =="S":
	print("天気が雨である日が連続していた最大の日数を出力せよ。")
if A == "sss":
	print(0)
if A == "rss" or "srs" or "ssr" or "rsr":
  print(1)
if A == "srr" or "rrs":
  print(2)
if A == "rrr":
  print(3)

A = input()
if A == "S"
	print("天気が雨である日が連続していた最大の日数を出力せよ。")
if A = "SSS"
	print(0)
if A == "RSS" or "SRS" or "SSR" or "RSR":
  print(1)
if A == "SRR" or "RRS":
  print(2)
if A == "RRR":
  print(3)

A = input("")
if A == "S"
	print("天気が雨である日が連続していた最大の日数を出力せよ。")
if A = "SSS"
	print(0)
if A == "RSS" or "SRS" or "SSR" or "RSR":
  print(1)
if A == "SRR" or "RRS":
  print(2)
if A == "RRR":
  print(3)

A = input("")
if A == "sss":
	print(0)
elif A == "rrr":
  print(3)  
elif A ==  "srr" or A == "rrs":
  print(2)
else:
  print(1)

A = input("")
if A =="S":
	print("天気が雨である日が連続していた最大の日数を出力せよ。")
elif A == "sss":
	print(0)
elif A == "rrr":
  print(3)  
elif A ==  "srr" or A == "rrs":
  print(2)
else:
  print(1)

A = input()
if A == "sss":
	print(0)
elif A == "rrr":
  print(3)  
elif A ==  "srr" or A == "rrs":
  print(2)
else:
  print(1)

A = input("晴れならs,雨ならrを入力してください")
if A =="S":
	print("天気が雨である日が連続していた最大の日数を出力せよ。")
elif A == "sss":
	print(0)
elif A == "rrr":
  print(3)  
elif A ==  "srr" or A == "rrs":
  print(2)
else:
  print(1)

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

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Runtime Error

Runtime Error

Wrong Answer

Wrong Answer

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):
S = input()
ma = 0
i = 0
m = 0
while(i != len(S)):
  print(i)
  if S[i] == "R":
    m += 1
  else:
    ma = max(ma,m)
    m = 0
  i += 1

print(ma)

S = input()
max = 0
i = 0
m = 0
while(i != len(S)):
  if S[i] == "R":
    m += 1
  
  else:
    max = max(max,m)
    m = 0
    break
  i += 1

print(max)

s = input()
count = 0
ans = 0

for i in range(len(s)):
  if(s[i] == "R"):
    count += 1
  else:
    ans = max(count, ans)
    count = 0
ans = max(count, ans)
print(ans)

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):
x,k,d = map(int,input().split())
x = abs(x)
if x//d > k:
  print(x-k*d)
elif (k-x//d)%2 == 0:
  print(x%d)
else:
  print(d-x%d)

s = input()
#print(s[0])
if s[0]==s[1]==s[2]=="R":
    print(3)
elif s[0]=="R" and s[1]=="R":
    print(2)
elif s[1]=="R" and s[2]=="R":
    print(2)
elif s[0]=="R":
    print(1)
elif s[1]=="R":
    print(1)
elif s[2]=="R":
    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=str(input())

ans = 0
if S == "SSS":
	ans = 0
	break
elif S == "SSR" or S == "RSS" or S = "RSR":
	ans = 1
	break
elif S == "SRR" or S == "RRS":
	ans = 2
	break
elif S == "RRR":
	ans = 3
	break
print(ans)

S=str(input())

ans = 0
if S == "SSS":
	ans = 0
elif S == "SSR" or S == "RSS" or S == "RSR" or S == "SRS":
	ans = 1
elif S == "SRR" or S == "RRS":
	ans = 2
elif S == "RRR":
	ans = 3
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):
s=input()
if s=="RRR":
	print(3)
elif s=="RRS" or s=="SRR":
	print(2)
elif s=="SSR" or s=="SRS" or s=="RSS" or s=="RSR”:
	print(1)
else:
	print(0)

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

s=input()
if s=="RRR":
	print(3)
elif s=="RRS" or s=="SRR":
	print(2)
elif s=="SSR" or s=="SRS" or s=="RSS" or s=="RSR":
	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 = str(input())
if s == "RRR":
  print(3)
elif s == "RRS" or s == "SRR":
  print(2)
elif s == "SSS":
  print(0)
else:
  print(1)
print(s)

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

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

row_now = 0
row_max = 0
for day in S:
    if day == "S":
        row_now += 1
    else:
        row_now = 0
    if row_now > row_max:
        row_max = row_now

print(row_max)


S = input()

row_now = 0
row_max = 0
for day in S:
    if day == "R":
        row_now += 1
    else:
        row_now = 0
    if row_now > row_max:
        row_max = row_now

print(row_max)


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):
temp = input()
return print(temp.count('R'))


weather = input()
rainyDay = weather.count('R')
if rainyDay < 2:
    print(rainyDay)
else:
    if weather[1] == 'R':
        print(rainyDay)
    else:
        print(1)


Verdicts: Runtime Error

Accepted