problem_id
stringlengths 6
6
| user_id
stringlengths 10
10
| time_limit
float64 1k
8k
| memory_limit
float64 262k
1.05M
| problem_description
stringlengths 48
1.55k
| codes
stringlengths 35
98.9k
| status
stringlengths 28
1.7k
| submission_ids
stringlengths 28
1.41k
| memories
stringlengths 13
808
| cpu_times
stringlengths 11
610
| code_sizes
stringlengths 7
505
|
---|---|---|---|---|---|---|---|---|---|---|
p02582 | u718499330 | 2,000 | 1,048,576 | 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. | ["c = 0\nfor i in input():\n if i=='R':\n c+=1\n else:\n c = 0\nprint(c)", "s = input()\nc = 0\nfor i in s:\n if i=='R':\n c+=1\n else:\n c-=1\nprint(c)", "s = input()\nc = 0\nfor i in s:\n if i=='R':\n c+=1\n else:\n c=0", "c = 0\nfor i in input():\n if i=='R':\n c+=1\nif c==3:\n print(3)\nelse:\n print(1)", "c = 0\nfor i in input().split():\n if i=='R':\n c +=1\nprint(c)", "c = 0\nr = []\nfor i in input():\n if i=='R':\n c+=1\n else:\n r.append(c)\n c = 0\nif not len(r):\n print(c)\nelse:\n print(max(c))", "c = 0\nr = []\nfor i in input():\n if i=='R':\n c+=1\n else:\n r.append(c)\n c = 0\nr.append(c)\nif not len(r):\n print(c)\nelse:\n print(max(r))"] | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Accepted'] | ['s027408537', 's113914159', 's266635690', 's817572656', 's855763098', 's900425268', 's783673945'] | [8908.0, 8996.0, 8980.0, 9024.0, 8984.0, 9028.0, 9096.0] | [24.0, 28.0, 28.0, 30.0, 27.0, 29.0, 25.0] | [72, 77, 67, 82, 63, 134, 146] |
p02582 | u718536599 | 2,000 | 1,048,576 | 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. | ["s=list(input())\ns=[str(x) for x in s]\ncount=0\nnum=0\nfor i in range(len(s)):\n if (s[i]=='R'):\n count+=1\n if(count==2):\n num+=1\n count=1\n elif (s[i]=='S'):\n count=0\n \nprint(num)", "s=list(input())\ns=[str(x) for x in s]\nprint(s)\ncount=0\nnum=0\nfor i in range(len(s)):\n if (s[i]=='R'):\n count+=1\n if(count==2):\n num+=1\n count=1\n elif (s[i]=='S'):\n count=0\n \nprint(num)", "s=list(input())\ns=[str(x) for x in s]\ncount=0\nnum=[0]\nfor i in range(len(s)):\n if (s[i]=='R'):\n count+=1\n num.append(count)\n elif (s[i]=='S'):\n count=0\n \nprint(max(num))"] | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s204986913', 's501333966', 's774199462'] | [9132.0, 8860.0, 8952.0] | [28.0, 29.0, 29.0] | [199, 208, 183] |
p02582 | u720124072 | 2,000 | 1,048,576 | 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. | ['s = input()\nif s = "RSR":\n print(1)\nelse:\n print(s.count("R"))', 's = input()\nif s == "RSR":\n print(1)\nelse:\n print(s.count("R"))\n'] | ['Runtime Error', 'Accepted'] | ['s737382341', 's587823903'] | [8940.0, 8964.0] | [26.0, 29.0] | [64, 66] |
p02582 | u726034675 | 2,000 | 1,048,576 | 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. | ["str = input()\nsplited = list(str)\n\ncccount = 0\ncount = 0\nfor s in splited:\n if s == 'R':\n count = count + 1\n else:\n if cccount > count:\n cccount = count\n count = 0\nprint(cccount)\n ", "str = input()\nsplited = str.split('')\nprint(splited)", "str = input()\nsplited = list(str)\n\ncccount = 0\ncount = 0\nfor s in splited:\n if s == 'R':\n count = count + 1\n if count > cccount:\n cccount = count\n else:\n count = 0\n \nprint(cccount)\n "] | ['Wrong Answer', 'Runtime Error', 'Accepted'] | ['s425836957', 's770684618', 's498619608'] | [9040.0, 9088.0, 8916.0] | [28.0, 27.0, 28.0] | [199, 52, 206] |
p02582 | u728235145 | 2,000 | 1,048,576 | 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. | ['vi = 0\nj = 0\nfor s in input():\n j += 1\n\n if s == "R":\n i += 1\n if j != 3 and i > 0 and s == "S":\n i -= 1\n\nprint(i)', 'i = 0\nj = 0\nk = 0\n\nw = ""\nfor s in input():\n j += 1\n\n if s == "S":\n k += 1\n\n if s == "S" and i > 0 and j == 2 and w != "R":\n i -= 1\n\n if s == "R" and (w == "R" or w == ""):\n i += 1\n elif s == "R" and w != s:\n i += 1 \n \n if w == "S":\n i = 1\n \n w = s\n\nif k == 3:\n i = 0\n\nprint(i)'] | ['Runtime Error', 'Accepted'] | ['s854605987', 's371774357'] | [9020.0, 8800.0] | [26.0, 28.0] | [137, 345] |
p02582 | u729679908 | 2,000 | 1,048,576 | 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. | ['x = max(map(len,input().split(S)))\nprint(x)', 'x = max(map(len,input().split("S")))\nprint(x)\n'] | ['Runtime Error', 'Accepted'] | ['s237990870', 's569175574'] | [9008.0, 9076.0] | [26.0, 31.0] | [43, 46] |
p02582 | u731436822 | 2,000 | 1,048,576 | 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. | ['\nX,K,D=map(int,input().split())\n\nq=abs(X)//D\nif q>K:\n print(abs(X)-K*D)\nelse:\n if (K-q)%2==0:\n print(abs(X)-q*D)\n else:\n print(abs(abs(X)-(q+1)*D))', "n = input()\n\nif 'RRR' in n:\n print(3)\nelif 'RR' in n:\n print(2)\nelif 'R' in n:\n print(1)\nelse:\n print(0)"] | ['Runtime Error', 'Accepted'] | ['s063604013', 's969933186'] | [9180.0, 8888.0] | [23.0, 35.0] | [202, 116] |
p02582 | u731461064 | 2,000 | 1,048,576 | 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. | ['a,b,c = input()\ncount = 0\n\nif a == "R":\n count = count + 1\nelse:\n count = 0\n \nif b == "R":\n count = count + 1\nelse:\n count = 0\n \nif c == "R":\n count = count + 1\nelse:\n count = 0\n \nprint(count)', 'a,b,c = input()\ncount = 0\n\nif a == "R" and b == "R" and c == "R":\n count = 3\nelif (a == "R" and b == "R") or(b == "R" and c == "R"):\n count = 2\nelif a == "R"or b =="R" or c == "R":\n count = 1\nelse:\n count = 0\n \nprint(count)'] | ['Wrong Answer', 'Accepted'] | ['s319217258', 's135464485'] | [9100.0, 9044.0] | [30.0, 32.0] | [201, 228] |
p02582 | u735011400 | 2,000 | 1,048,576 | 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. | ["l = list(input())\na = 0\nb = False\nfor v in l:\n if v == 'R':\n b = True\n else:\n b = False\n a = 0\n \n if b:\n a += 1\n\nprint(a)", "l = list(input())\na = False\nb = False\nc = False\n\n\nif l[0] == 'R':\n\ta = True\nif l[1] == 'R':\n\tb = True\nif l[2] == 'R':\n \tc = True\n \nif a and b and c:\n \tprint(3)\nelif (a and b) or (b and c):\n \tprint(2)\nelif a or b or c:\n \tprint(1)\nelse:\n \tprint(0)"] | ['Wrong Answer', 'Accepted'] | ['s664535157', 's194320234'] | [9000.0, 8924.0] | [29.0, 26.0] | [165, 253] |
p02582 | u735260810 | 2,000 | 1,048,576 | 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. | ['s = list(input())\nl = len(s)\nrain =int()\nfor x in range(l):\n if s[x]=="R":\n rain=rain+1\n else:\n rain=0\nprint(rain)', 's = list(input())\nl = len(s)\nrain =int()\nmaxrain =int()\nfor x in range(l):\n if s[x]=="R":\n rain=rain+1\n maxrain=rain\n else:\n rain=0\n maxrain=maxrain\nprint(maxrain)'] | ['Wrong Answer', 'Accepted'] | ['s371959837', 's950038426'] | [8980.0, 9040.0] | [35.0, 25.0] | [122, 177] |
p02582 | u742729271 | 2,000 | 1,048,576 | 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. | ['s = input()\nans=0\nfor i in range(len(s)):\n if s[i] == "S":\n ans+=1\n elif i>len(s):\n break\n \nprint(ans)', 's = input()\nans=0\nif "SSS" in s:\n print(3)\nelif "SS" in s:\n print(2)\nelif "S" in s:\n print(1)\nelse:\n print(0)', 's = input()\nans=0\nif "RRR" in s:\n print(3)\nelif "RR" in s:\n print(2)\nelif "R" in s:\n print(1)\nelse:\n print(0)'] | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s311478869', 's628674805', 's412654441'] | [9096.0, 9052.0, 9032.0] | [29.0, 27.0, 33.0] | [113, 113, 113] |
p02582 | u743164083 | 2,000 | 1,048,576 | 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. | ['n = int(input())\nl = list(map(int, input().split()))\nans = 0\nfor i in range(n):\n for j in range(i + 1, n):\n for k in range(j + 1, n):\n if l[i] == l[j] or l[j] == l[k] or l[k] == l[i]:\n continue\n\n else:\n \n if l[i] + l[j] > l[k] and l[j] + l[k] > l[i] and l[k] + l[i] > l[j]:\n ans += 1\nprint(ans)\n', 's = list(input())\nc = s.count("R")\nif c == 3:\n print(3)\nelif c == 2 and s[1] != "S":\n print(2)\nelif c == 0:\n print(0)\nelse:\n print(1)\n'] | ['Runtime Error', 'Accepted'] | ['s761786541', 's990995357'] | [9188.0, 8892.0] | [21.0, 27.0] | [415, 146] |
p02582 | u745269298 | 2,000 | 1,048,576 | 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. | ['text = input()\nif text[1] == "S":\n\tif text[0] == "R" or text[2] == "R":\n \tprint(1)\n else:\n print(0)\nelse:\n if text[0] == "R" and text[2] == "R":\n \tprint(3)\n elif text[0] == "R" or text[2] == "R":\n print(2)', ' text = input()\n if text[1] == "S":\n if text[0] == "R" or text[2] == "R":\n print(1)\n else:\n print(0)\n else:\n if text[0] == "R" and text[2] == "R":\n print(3)\n elif text[0] == "R" or text[2] == "R":\n print(2)', 'text = input()\nif text[1] == "S":\n if text[0] == "R" or text[2] == "R":\n print(1)\n else:\n print(0)\nelse:\n if text[0] == "R" and text[2] == "R":\n print(3)\n elif text[0] == "R" or text[2] == "R":\n print(2)\n else:\n print(1)\n\n'] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s320333819', 's538539388', 's775444836'] | [9000.0, 8996.0, 9104.0] | [25.0, 30.0, 29.0] | [234, 287, 272] |
p02582 | u747325600 | 2,000 | 1,048,576 | 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. | ["A = list(map(input().split()))\n\ncnt = A.conunt('R')\nif cnt = 2:\n if A(2) == 'S':\n cnt =1\n ", "A = input()\n\ncnt = A.count('R')\nif cnt == 2:\n ccc = A.find('S')\n if ccc == 1:\n cnt =1\n\nprint(cnt)"] | ['Runtime Error', 'Accepted'] | ['s662651568', 's700742023'] | [9028.0, 8908.0] | [29.0, 31.0] | [97, 102] |
p02582 | u750958070 | 2,000 | 1,048,576 | 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. | ["A = input().split()\ncount = 0\nfor a in range(3)\n if A[a] == 'R':\n count++\n \nif count == 2 A[1] == 'S':\n count = 1\nprint(count)\n ", "A = input().split()\ncount = 0\nfor a in range(3):\n if A[a] == 'R':\n count++\n \nif count == 2 A[1] == 'S':\n count = 1\nprint(count)", "A = input()\ncount = 0\nfor a in range(3):\n if A[a] == 'R':\n count+=1\n \nif count == 2 and A[1] == 'S':\n count = 1\nprint(count)"] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s758678556', 's866162927', 's290142508'] | [8904.0, 8872.0, 8940.0] | [24.0, 25.0, 29.0] | [153, 145, 142] |
p02582 | u754869388 | 2,000 | 1,048,576 | 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. | ["import re\ns=input()\n\nif s == 'RRR':\n print(3)\nelif re.search(s , 'RR'):\n print(2)\nelif re.search(s, 'R'):\n print(1)\nelse:\n print(0)", "import re\ns=input()\n\nif s == 'RRR':\n print(3)\nelif re.search('RR',s):\n print(2)\nelif re.search('R',s):\n print(1)\nelse:\n print(0)"] | ['Wrong Answer', 'Accepted'] | ['s703476095', 's649719830'] | [9668.0, 9932.0] | [36.0, 36.0] | [135, 132] |
p02582 | u760802228 | 2,000 | 1,048,576 | 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. | ['S = input()\nc = 0\nfor i in S:\n if i == "R":\n c += 1\n else:\n c = 0\nprint(c)', 'S = input()\nif S == "RRR":\n print(3)\nelif S == "SRR" or S == "RRS":\n print(2)\nelif S == "SSS":\n print(0)\nelse:\n print(1)'] | ['Wrong Answer', 'Accepted'] | ['s837833394', 's480608512'] | [8988.0, 9040.0] | [28.0, 31.0] | [118, 148] |
p02582 | u762523240 | 2,000 | 1,048,576 | 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. | ["S = input()\nif S == 'RRR':\n print(3)\nelif S[:3] == 'RR' or S[1:] == 'RR':\n print(2)\nelif S == 'SSS':\n print(0)\nelse:\n print(1)", "wether = input()\nif wether == 'SSS':\n print(0)\nelif wether == 'RRR':\n print(3)\nelif wether[:2] == 'RR' or wether[1:] == 'RR':\n print(2)\nelse:\n print(1)"] | ['Wrong Answer', 'Accepted'] | ['s253571350', 's838110937'] | [9040.0, 9064.0] | [29.0, 25.0] | [130, 163] |
p02582 | u762533651 | 2,000 | 1,048,576 | 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. | ["# -*- coding: utf-8 -*-\n\nS = input()\nz = S.count('R')\n\nif S == 'RRR':\n print(3)\nelif S == 'RRS' and S == 'SRR':\n print(2)\nelif z == 1 or S == 'RSR':\n print(1)\nelse:\n print(0)\n", "\nS = input()\n\nif S == 'RRR':\n print(3)\nelif S == 'RRS' or S == 'SRR':\n print(2)\nelif S.count('R') == 1 or S == 'RSR':\n print(1)\nelse:\n print(0)"] | ['Wrong Answer', 'Accepted'] | ['s449821234', 's959117726'] | [9032.0, 8996.0] | [29.0, 38.0] | [188, 156] |
p02582 | u763628696 | 2,000 | 1,048,576 | 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. | ['\na = input()\nif "RRR" in a:\n print(3)\n elif "RR" in a:\n print(2)\n elif "R" in a:\n print(1)\n else:\n primt(0)', "str1 = input()\nstr2 = 'R'\nstr3 = 'RR'\nstr4 = 'RRR'\nans = 0\nif str4 in str1\nans = 3\nelif str3 in str1\nans = 2\nelif str3 in str1\nans = 2\nelse\nans=0\n\nprint(ans)", 'a = input()\nif "RRR" in a:\n print(3)\nelif "RR" in a:\n print(2)\nelif "R" in a:\n print(1)\nelse:\n print(0)'] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s545550585', 's705821666', 's033527431'] | [8932.0, 8956.0, 9084.0] | [28.0, 28.0, 28.0] | [126, 157, 107] |
p02582 | u771007149 | 2,000 | 1,048,576 | 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. | ["s = input()\n\ncnt = 0\nfor i in range(2):\n if s[i] == 'R':\n if s[i+1] == 'R':\n cnt += 1\nprint(cnt)", "s = input()\n\ncnt = 0\nif 'RRR' in s:\n print(3)\nelif 'RR' in s:\n print(2)\nelif 'R' in s:\n print(1)\nelse:\n print(0)\n"] | ['Wrong Answer', 'Accepted'] | ['s220891408', 's894111984'] | [8940.0, 8980.0] | [30.0, 26.0] | [117, 125] |
p02582 | u779293207 | 2,000 | 1,048,576 | 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. | ["S=input()\nd=0\nc=0\nfor i in range(len(S)):\n if i=='S':\n break\n else:\n c+=1\n if c>d:\n d=c\n c=0\nprint(d)\n \n ", "S=input()\nd=0\nc=0\nfor i in range(len(S)):\n if S[i]=='S':\n c=0\n else:\n c+=1\n if c>d:\n d=c\nprint(d)\n \n \n \n"] | ['Wrong Answer', 'Accepted'] | ['s232943536', 's981080848'] | [9088.0, 9116.0] | [29.0, 27.0] | [119, 118] |
p02582 | u780147002 | 2,000 | 1,048,576 | 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. | ["S = input()\nRD = weather.count('R')\nif RD < 2:\n print(RD)\nelse:\n if S[1] == 'R':\n print(RD)\n else:\n print(1)", "weather = input()\nrainyDay = weather.count('R')\nif rainyDay < 2:\n print(rainyDay)\nelse:\n if weather[1] == 'R':\n print(rainyDay)\n else:\n print(1)"] | ['Runtime Error', 'Accepted'] | ['s071832374', 's035940163'] | [9020.0, 9068.0] | [29.0, 30.0] | [131, 167] |
p02582 | u783229769 | 2,000 | 1,048,576 | 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. | ['num_bars = int(input())\nlength_list = list(map(int,input().split()))\nlength_list.sort()\n#print(length_list)\n\ncount = 0\n\nfor i in range(num_bars):\n a = length_list[i]\n for j in range(i + 1,num_bars):\n b = length_list[j]\n if a == b:\n continue\n else :\n for k in range(j + 1,num_bars):\n c = length_list[k]\n if b == c:\n continue\n if a + b <= c:\n continue\n count += 1\n\n \nprint(count)\n \n# for j in \n', 'num_bars = 3\nlength_list = list(map(int,input().split()))\n\nx = abs(length_list[0])\nk = length_list[1]\nd = length_list[2]\n\namari = x % d\nsyou = x // d\n\n#print(amari)\n#print(syou)\n\nval = x\n\nif x - k * d > amari:\n val = x - k * d\nelif (k - syou ) % 2 == 0:\n val = amari\nelse :\n val = d - amari\n \n \nprint(val)\n \n ', "s = input()\nnum = 0\nnum2 = 0\nfor i in range (3) :\n# print(s[i])\n\n yesterday = 'R'\n if s[i] == 'R':\n if yesterday == 'R':\n num2 += 1\n else :\n yesterday = 'R'\n else :\n yesterday = 'S'\n if num2 > num:\n num = num2\n num2 = 0\n\n\nif num2 > num:\n num = num2\n\n\nprint(num)"] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s132377408', 's521111703', 's759993559'] | [9124.0, 9180.0, 9116.0] | [22.0, 27.0, 32.0] | [474, 317, 298] |
p02582 | u785728112 | 2,000 | 1,048,576 | 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. | ['s = list(input())\nif (s[0]=="S" and s[1]=="S" and s[2]=="S"):\n print(3)\nelif (s[0]=="S" and s[1]=="S") or (s[1]=="S" and s[2]=="S"):\n print(2)\nelif s[0]!="S" and s[1]!="S" and s[2]!="S":\n print(0)\nelse:\n print(1)\n\n', 's = list(input())\nif (s[0]=="R" and s[1]=="R" and s[2]=="R"):\n print(3)\nelif (s[0]=="R" and s[1]=="R") or (s[1]=="R" and s[2]=="R"):\n print(2)\nelif s[0]!="R" and s[1]!="R" and s[2]!="R":\n print(0)\nelse:\n print(1)\n\n'] | ['Wrong Answer', 'Accepted'] | ['s476631029', 's955438200'] | [9112.0, 8976.0] | [31.0, 31.0] | [239, 239] |
p02582 | u787466693 | 2,000 | 1,048,576 | 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. | ['import itertools\n\nX,K,D = map(int,input().split())\nL = [D,-D]\ncomb = list(itertools.combinations_with_replacement(L, K))\n\nfor i in range(len(comb)):\n x = X\n for d in comb[i]:\n x = x + d\n if(i == 0):\n x_min = x\n if(abs(x) < abs(x_min)):\n x_min = x\n\nprint(abs(x_min))\n \n \n', 'import itertools\n\nX,K,D = map(int,input().split())\nL = [D,-D]\n\nfor comb in itertools.combinations_with_replacement(L, K):\n x = X\n for d in comb:\n x = x + d\n if(i == 0):\n x_min = x\n if(abs(x) < abs(x_min)):\n x_min = x\n\nprint(abs(x_min))\n \n \n', 'a,b,c = map(str,input().rstrip(""))\n\n\nif(a=="R" and b == "R" and c == "R"):\n count = 3\n \nelif(a=="R" and b == "R" and c == "S"):\n count = 2\nelif(a=="R" and b == "S" and c == "S"):\n count = 1\nelif(a=="S" and b == "R" and c == "R"):\n count = 2\nelif(a=="S" and b == "R" and c == "S"):\n count = 1\nelif(a=="S" and b == "S" and c == "R"):\n count = 1\nelif(a=="R" and b == "S" and c == "R"):\n count = 1\nelse:\n count = 0\n\nprint(count)\n \n \n \n '] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s323532252', 's805102807', 's411857154'] | [9196.0, 9180.0, 9080.0] | [24.0, 29.0, 35.0] | [297, 267, 446] |
p02582 | u797572808 | 2,000 | 1,048,576 | 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. | ['s = list(input())\n\nif(s[0] == s[1] == s[2] == "R"):\n ans = 3\nelif(s[0] == s[1] == "R" or s[2] == s[1] == "R"):\n ans = 2\nelif(s[0] == s[1] == s[2] == "S"):\n ans = 0\nelse:\n ans = 1\n\npritn(ans)\n', 's = list(input())\n\nif(s[0] == s[1] == s[2] == "R"):\n ans = 3\nelif(s[0] == s[1] == "R" or s[2] == s[1] == "R"):\n ans = 2\nelif(s[0] == s[1] == s[2] == "S"):\n ans = 0\nelse:\n ans = 1\n\nprint(ans)\n\n'] | ['Runtime Error', 'Accepted'] | ['s830111675', 's358448877'] | [9048.0, 8988.0] | [24.0, 32.0] | [203, 204] |
p02582 | u801617021 | 2,000 | 1,048,576 | 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. | ["str1=input()\nct=0\nfor i in range(0,3):\n if(str1[i]=='S')\n ct+=1\nif(ct==0):\n print(3)\nif(ct==3):\n print(0)\nif(ct==2):\n print(1)\nif(ct==1):\n if(str1[1]=='S'):\n print(1)\n else:\n print(2)", "str1=input()\nct=0\nfor i in range(0,3):\n if(str1[i]=='S'):\n ct+=1\nif(ct==0):\n print(3)\nif(ct==3):\n print(0)\nif(ct==2):\n print(1)\nif(ct==1):\n if(str1[1]=='S'):\n print(1)\n else:\n print(2)\n"] | ['Runtime Error', 'Accepted'] | ['s140454092', 's753372116'] | [9008.0, 8920.0] | [34.0, 27.0] | [196, 224] |
p02582 | u802662134 | 2,000 | 1,048,576 | 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. | ['S=input()\nif S[1]=="R":\n if S[2]=="R":\n if S[3]=="R":\n print(3)\n else:\n print(2)\n else:\n print(1)\nelif S[2]=="R":\n if S[3]=="R":\n print(2)\n else:\n print(1)\nelif S[3]=="R":\n print(1)\nelse:\n print(0)', "S=input()\nif S[1-1]=='R':\n if S[2-1]=='R':\n if S[3-1]=='R':\n print(3)\n else:\n print(2)\n else:\n print(1)\nelif S[2-1]=='R':\n if S[3-1]=='R':\n print(2)\n else:\n print(1)\nelif S[3-1]=='R':\n print(1)\nelse:\n print(0)"] | ['Runtime Error', 'Accepted'] | ['s658381697', 's799682341'] | [9108.0, 9040.0] | [27.0, 29.0] | [228, 240] |
p02582 | u804733539 | 2,000 | 1,048,576 | 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. | ["s=input()\nans = 0\nif 'SSS' in s:\n ans = 3\nelif 'SS' in s:\n ans = 2\nelif 'S' in s:\n ans = 1\nprint(ans)", "s=input()\nans = 0\nif 'SSS' in s:\n ans = 3\nelif: 'SS' in s:\n ans = 2\nelif: 'S' in s:\n ans = 1\nprint(ans)", "s=input()\nans = 0\nif 'RRR' in s:\n ans = 3\nelif 'RR' in s:\n ans = 2\nelif 'R' in s:\n ans = 1\nprint(ans)"] | ['Wrong Answer', 'Runtime Error', 'Accepted'] | ['s093993806', 's963200050', 's083769655'] | [9004.0, 8892.0, 9020.0] | [35.0, 21.0, 33.0] | [104, 106, 104] |
p02582 | u805066078 | 2,000 | 1,048,576 | 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. | ["s = input()\nn = 0\nfor i in range(3):\n if s[i] == 'R':\n n += 1\n else:\n n = 0\nprint(n)\n\n ", "s = input()\n\nif s.count('R') == 3 :\n print(3)\nelif s.count('R') == 1:\n print(1)\nelif s.count('R') == 0:\n print(0)\nelif s.count('R') == 2:\n res = [i for i in range(len(s)) if s.startswith('R', i)]\n if sum(res) == 2:\n print(1)\n else:\n print(2)\n "] | ['Wrong Answer', 'Accepted'] | ['s052822883', 's775349393'] | [9020.0, 8916.0] | [29.0, 29.0] | [98, 256] |
p02582 | u806691350 | 2,000 | 1,048,576 | 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. | ['x, k, d = map(int, input().split())\ndistance = k * d\nresult = abs(x - distance)\n\n\nwhile distance >= 0:\n distance -= d * 2\n if result > result = abs(x - distance):\n result = abs(x - distance)\n \nprint(result)', 's1, s2, s3 = str(input())\nif s1 == "R":\n if s2 == "S":\n result = 1\n else:\n if s3 == "S":\n result = 2\n else:\n result = 3\nelse:\n if s2 == "S":\n if s3 == "S":\n result = 0\n else:\n result = 1\n else:\n if s3 == "S":\n result = 1\n else:\n result = 2\n\nprint(result)'] | ['Runtime Error', 'Accepted'] | ['s398554808', 's134319723'] | [8916.0, 9112.0] | [30.0, 31.0] | [214, 309] |
p02582 | u808569469 | 2,000 | 1,048,576 | 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. | ['text = input()\nif text == "RRS":\n print(2)\nelif text == "SSS":\n print(0)\nelse text == "RSR":\n print(1)', 'a = max(input().split("S"))\nprint(len(a))'] | ['Runtime Error', 'Accepted'] | ['s454434110', 's657289304'] | [8860.0, 9012.0] | [22.0, 28.0] | [111, 41] |
p02582 | u809108154 | 2,000 | 1,048,576 | 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. | ['S = map(str, input())\nprint(S)', 'S=str(input())\nif len(S)==3:\n if "RRR" in S:\n print(3)\n elif "RR" in S:\n print(2)\n elif "R" in S:\n print(1)\n else:\n print(0)'] | ['Wrong Answer', 'Accepted'] | ['s657168481', 's288552357'] | [8944.0, 9060.0] | [30.0, 27.0] | [30, 140] |
p02582 | u809153881 | 2,000 | 1,048,576 | 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. | ['s = input()\nif s.contains("RRR"):\n print(3)\nelif s.contains("RR"):\n print(2)\nelif s.contains("R"):\n print(1)\nelse:\n print(0)', 's = input()\nif "RRR" in s:\n print(3)\nelif "RR" in s:\n print(2)\nelif "R" in s:\n print(1)\nelse:\n print(0)\n'] | ['Runtime Error', 'Accepted'] | ['s376712020', 's095182547'] | [9008.0, 9008.0] | [24.0, 31.0] | [128, 108] |
p02582 | u813042907 | 2,000 | 1,048,576 | 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. | ['import numpy\n\ne=input().split()\nfor i in range(len(e)):\n e[i]=int(e[i])\nx=e[0]\nk=e[1]\nd=e[2]\nt=k\nif k>10000:\n if k%2==0:\n t=10000\n else:\n t=10001\nkou=numpy.gcd(x,d)\nx=int(x/kou)\nd=int(d/kou)\nif d>100 and d%2==0:\n d=100\nif d>100 and d%2==1:\n d=1001\nfor i in range(t):\n if abs(x+d)<abs(x-d):\n x+=d\n else:\n x-=d\nprint(abs(x)*kou)\n', 'w=input()\ncount=0\n\nif w=="SSS":\n print(0)\nif w=="SSR":\n print(1)\nif w=="SRR":\n print(2)\nif w=="RRS":\n print(2)\nif w=="RSR":\n print(1)\nif w=="SRS":\n print(1)\nif w=="RSS":\n print(1)\nif w=="RRR":\n print(3)'] | ['Runtime Error', 'Accepted'] | ['s420397132', 's034154573'] | [27056.0, 9116.0] | [120.0, 35.0] | [342, 202] |
p02582 | u818854517 | 2,000 | 1,048,576 | 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. | ['s=input()\nif \'RRR\' in s:\n print (\'3\')\nif \'RR\' in s:\n print (\'2")\nif \'R\' in s:\n print(\'1\')\nelse:\n print(\'0\')', "s=input()\nif 'RRR' in s:\n print ('3')\nelif 'RR' in s:\n print ('2')\nelif 'R' in s:\n print('1')\nelse:\n print('0')"] | ['Runtime Error', 'Accepted'] | ['s350376113', 's396226250'] | [8944.0, 9112.0] | [26.0, 34.0] | [119, 123] |
p02582 | u827261928 | 2,000 | 1,048,576 | 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. | ['a=0\nS=input()\nfor i in range(2):\n if(S[i]==S[i+1]):\n a=a+1\nprint(a)', "a=0\nS=input()\nif('R' in S):\n a=1\nfor i in range(2):\n if(S[i]==S[i+1] and S[i]=='R'):\n a=a+1\nprint(a)"] | ['Wrong Answer', 'Accepted'] | ['s940168142', 's927531559'] | [8956.0, 9104.0] | [26.0, 27.0] | [77, 113] |
p02582 | u827765795 | 2,000 | 1,048,576 | 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. | ['X, K, D = map(int, input().split())\nX = abs(X)\nr = X % D\nt = X // D\nif t >= K:\n ans = abs(X - K * D)\nelif (K - t) % 2 == 0:\n ans = r\nelse:\n ans = D - r\nprint(ans)', 'X, K, D = map(int, input().split())\nX = abs(X)\npoint = X % D\nq = X // D\nans = 0\nif q >= K:\n ans = abs(X-D*K)\nelif (K - q) % 2 == 0:\n ans = point\nelse:\n ans = D-point\nprint(ans)', "S = input()\ncnt = 0\nans = 0\nfor s in S:\n if s == 'R':\n cnt += 1\n else:\n cnt = 0\n ans = max(ans, cnt)\nprint(ans)"] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s839831883', 's933672639', 's341468524'] | [9060.0, 9116.0, 8932.0] | [26.0, 29.0, 26.0] | [171, 185, 134] |
p02582 | u833436666 | 2,000 | 1,048,576 | 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. | ['import sys\nimport math\nX,K,D = map(int, input().split()) \nX1=abs(X)\nsyou=math.floor(X1/D)\namari=math.floor(K/syou)\nans=0\nif amari==0:\n ans=X1-D*K\nelse:\n ya=math.floor(K/amari)\n ans=X1-ya*D\n if ya%2==0:\n print(ans)\n sys.exit()\n if abs(ans+D)>abs(ans-D):\n ans=ans-D\n else:\n ans=ans+D\nprint(abs(ans))', 'import sys\n\nS=input()\nans=0\nans=S.count("R")\nif ans==2 and S[1]=="S":\n print("1")\n sys.exit()\nprint(ans)'] | ['Runtime Error', 'Accepted'] | ['s905294666', 's079586955'] | [9072.0, 9028.0] | [22.0, 33.0] | [343, 110] |
p02582 | u833871588 | 2,000 | 1,048,576 | 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. | ["r=0\nfor l in input():\n r+=1 if l='R' else 0\nprint(r)", "print(max([len(x) for x in input().split('S')]))"] | ['Runtime Error', 'Accepted'] | ['s263922807', 's432189765'] | [9016.0, 9076.0] | [28.0, 30.0] | [53, 48] |
p02582 | u835090251 | 2,000 | 1,048,576 | 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. | ['#coding :utf-8\nS=input()\nif (S=="sss"):\n print(3)\nelif(S=="ssr"):\n print(2)\nelif(S=="srs"):\n print(1)\nelif(S=="rss"):\n print(1)\nelif(S=="srr"):\n print(2)\nelif(S=="rsr"):\n print(1)\nelif(S=="rrs"):\n print(2)\nelse:\n print(0)\n', '#coding :utf-8\nS=input()\nif (S=="sss"):\n print(3)\nelif(S=="ssr"):\n print(2)\nelif(S=="srs"):\n print(1)\nelif(S=="rss"):\n print(1)\nelif(S=="srr"):\n print(2)\nelif(S=="rsr"):\n print(1)\nelif(S=="rrs"):\n print(2)\nelse:\n print(0)\n', '#coding :utf-8\nS=input(">")\nif (S==sss):\n print(3)\nelif(S==ssr):\n print(2)\nelif(S==srs):\n print(1)\nelif(S==rss):\n print(1)\nelif(S==srr):\n print(2)\nelif(S==rsr):\n print(1)\nelif(S==rrs):\n print(2)\nelse:\n print(0)', '#coding :utf-8\nS=input(">")\nif (S=="sss"):\n print(3)\nelif(S=="ssr"):\n print(2)\nelif(S=="srs"):\n print(1)\nelif(S=="rss"):\n print(1)\nelif(S=="srr"):\n print(2)\nelif(S=="rsr"):\n print(1)\nelif(S=="rrs"):\n print(2)\nelse:\n print(0)\n', 'S=input()\nif S=="SSS":\n print(0)\nelif S=="SSR":\n print(1)\nelif S=="SRS":\n print(1)\nelif S=="RSS":\n print(1)\nelif S=="SRR":\n print(2)\nelif S=="RSR":\n print(1)\nelif S=="RRS":\n print(2)\nelse:\n print(3)'] | ['Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Wrong Answer', 'Accepted'] | ['s647140084', 's681074053', 's835397769', 's899931808', 's704295276'] | [9108.0, 9044.0, 9120.0, 8976.0, 9068.0] | [29.0, 31.0, 29.0, 29.0, 28.0] | [246, 246, 234, 249, 222] |
p02582 | u837340160 | 2,000 | 1,048,576 | 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. | ["S = int(input())\n\nflag = False\nans = 0\nfor i in range(len(S)):\n if S[i] == 'R':\n ans += 1\n flag = True\n elif S[i] == 'S' and flag:\n break\n\nprint(ans)\n", "S = int(input())\n\nflag = False\nans = 0\nfor i in range(len(S)):\n if S[i] == 'R':\n ans += 1\n flag = True\n elif S[i] == 'S' ans flag:\n break\n\nprint(ans)\n", "S = input()\n\nflag = False\nans = 0\nfor i in range(len(S)):\n if S[i] == 'R':\n ans += 1\n flag = True\n elif S[i] == 'S' and flag:\n break\n\nprint(ans)\n"] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s302046269', 's550229135', 's729808302'] | [9080.0, 8932.0, 8956.0] | [30.0, 25.0, 25.0] | [177, 177, 172] |
p02582 | u837507786 | 2,000 | 1,048,576 | 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. | ['S = input("R or S:")\ns = list(S)\n\ncount = 0\nfor i in s:\n if i == "R":\n count += 1\n else: count =0\nprint(count)', 'S = input()\ns = list(S)\n\ncount = 0\nfor i in s:\n if i == "R":\n count += 1\n else: count =0\nprint(count)', 'S = input()\ns = list(S)\n\ncount = 0\nmax_count = 0\n\nfor i in s:\n if i == "R":\n count += 1\n else: \n if max_count <= count:\n max_count = max(max_count,count) \n count =0\nif max_count <= count:\n max_count = count\nprint(max_count)\n'] | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s117064073', 's699779811', 's391638909'] | [9092.0, 9032.0, 8920.0] | [26.0, 28.0, 34.0] | [123, 114, 265] |
p02582 | u838296343 | 2,000 | 1,048,576 | 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. | ['N = int(input())\nL = map(int,input().split())\n\nsLength = set(L)\ncount = 0\n\nfor i in sLength:\n for j in sLength:\n for k in sLength:\n if i!=j and i!=k and j!=k:\n m = max([i,j,k])\n if i+j+k-2*m>0:\n count+=1\n\nprint(count)\n', "s = input()\n\ntable = {'RRR':3,'RRS':2,'RSR':1,'RSS':1,'SRS':1,'SRR':2,'SSS':0,'SSR':1}\n\nfor key,value in table.items():\n if key==s:\n print(value) "] | ['Runtime Error', 'Accepted'] | ['s024448218', 's846790814'] | [9036.0, 9100.0] | [25.0, 31.0] | [288, 156] |
p02582 | u843768197 | 2,000 | 1,048,576 | 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. | ["s = input()\ncount = 0\nif 'RRR' in s:\n print(3)\nelif 'RR' in s:\n print(2)\nelif 'SSR' in s or 'SRS' in s or 'RSS' in sor 'RSR' in s:\n print(1)\nelse:\n print(0)", "s = input()\ncount = 0\nif 'RRR' in s:\n print(3)\nelif 'RR' in s:\n print(2)\nelif 'SSR' in s or 'SRS' in s or 'RSS' in s or 'RSR' in s:\n print(1)\nelse:\n print(0)"] | ['Runtime Error', 'Accepted'] | ['s972718526', 's175850286'] | [9016.0, 9100.0] | [27.0, 34.0] | [160, 161] |
p02582 | u844895214 | 2,000 | 1,048,576 | 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. | ['import sys\nfrom collections import deque\nimport numpy as np\nimport math\nsys.setrecursionlimit(10**6)\ndef S(): return sys.stdin.readline().rstrip()\ndef SL(): return map(str,sys.stdin.readline().rstrip().split())\ndef I(): return int(sys.stdin.readline().rstrip())\ndef IL(): return map(int,sys.stdin.readline().rstrip().split())\n\ndef solve():\n return\n\nif __name__==\'__main__\':\n s = S()\n for rep in s:\n if rep=="RRR":\n print(3)\n elif rep=="RRS" or "SRR":\n print(2)\n elif rep=="SSS":\n print(0)\n else:\n print(1)\n solve()', 'import sys\nfrom collections import deque\nimport numpy as np\nimport math\nsys.setrecursionlimit(10**6)\ndef S(): return sys.stdin.readline().rstrip()\ndef SL(): return map(str,sys.stdin.readline().rstrip().split())\ndef I(): return int(sys.stdin.readline().rstrip())\ndef IL(): return map(int,sys.stdin.readline().rstrip().split())\n\ndef solve():\n return\n\nif __name__==\'__main__\':\n s = S()\n if s=="RRR":\n print(3)\n elif s=="RRS" or s=="SRR":\n print(2)\n elif s=="SSS":\n print(0)\n else:\n print(1)\n solve()'] | ['Wrong Answer', 'Accepted'] | ['s771817785', 's912393319'] | [26988.0, 27152.0] | [137.0, 132.0] | [598, 545] |
p02582 | u849756457 | 2,000 | 1,048,576 | 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. | ['S = input()\nc = 0\ncmax = 0\nfor c in S:\n if c == "R":\n c += 1\n if cmax < c:\n cmax = c\n else:\n c = 0\nprint(cmax)', 'S = input()\ncnt = 0\ncmax = 0\nfor c in S:\n if c == "R":\n cnt += 1\n if cmax < cnt:\n cmax = cnt\n else:\n cnt = 0\nprint(cmax)'] | ['Runtime Error', 'Accepted'] | ['s480447948', 's011752217'] | [8944.0, 9032.0] | [30.0, 33.0] | [126, 136] |
p02582 | u854244562 | 2,000 | 1,048,576 | 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. | ["S = input()\ns = [i for i in input()]\nif s.count('R') == 3:\n print(3)\nelif s.count('R') == 1:\n print(1)\nelif s.count('R') == 0:\n print(0)\nelse:\n if S == 'RSR':\n print(1)\n else:\n print(2)", "S = input()\ns = [i for i in S]\nif s.count('R') == 3:\n print(3)\nelif s.count('R') == 1:\n print(1)\nelif s.count('R') == 0:\n print(0)\nelse:\n if S == 'RSR':\n print(1)\n else:\n print(2)"] | ['Runtime Error', 'Accepted'] | ['s978475683', 's272752517'] | [8980.0, 9056.0] | [27.0, 25.0] | [214, 208] |
p02582 | u854780853 | 2,000 | 1,048,576 | 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. | ['S = input()\n\nif S.count("R") == 2 and S[1] != R:\n print(1)\n \nelse:\n print(S.count("R"))', 'S = input()\n\nif ("RRR" in S) == true:\n print(3)\nelif("RR" in S) == true:\n print(2)\nelif("R" in S) == true:\n print(1)\nelse:\n print(0)\n\n', 'S = input()\n \nif S.count("R") == 2 and S[1] != "R":\n print(1)\n \nelse:\n print(S.count("R"))'] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s249289699', 's914471768', 's897918833'] | [9092.0, 8952.0, 9032.0] | [26.0, 26.0, 25.0] | [90, 138, 93] |
p02582 | u854784579 | 2,000 | 1,048,576 | 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. | ['whether=input(str())\nif whether[1]==whether[2]==whether[3]=="R":\n print ("3")\nelif whether[1]==whether[2]==whether[3]=="S":\n print ("0")\nelif whether[1]==whether[2]=="R" or whether[2]==whether[3]=="R":\n print ("2")\nelse:\n print ("1")\n', 'whether=input(str())\nif whether[1]==whether[2]==whether[3]=="R":\n print ("3")\nelif whether[1]==whether[2]==whether[3]=="S":\n print ("0")\nelif whether[1]==whether[2]=="R" or whether[2]==whether[3]=="R":\n print ("2")\nelse:\n print ("1")\n', 'whether=str(input())\nif whether[0]==whether[1]==whether[2]=="R":\n print ("3")\nelif whether[0]==whether[1]==whether[2]=="S":\n print ("0")\nelif whether[0]==whether[1]=="R" or whether[1]==whether[2]=="R":\n print ("2")\nelse:\n print ("1")\n'] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s049689237', 's152759907', 's059121459'] | [8756.0, 9104.0, 9044.0] | [26.0, 32.0, 30.0] | [246, 246, 246] |
p02582 | u855057563 | 2,000 | 1,048,576 | 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. | ['l=input()\nif l="RRR":\n print(3)\nelif l="RRS" or "SRR":\n print(2)\nelif l="SSS":\n print(0)\nelse:\n print(1)\n ', 'l=input()\nif l="RRR":\n print(3)\nelif l="RRS" or "SRR":\n print(2)\nelif l="SSS":\n print(0)\nelse:\n print(1)\n \n', 'l=input()\nfor i in range(4):\n if "R"*i in l:\n ans=i\nprint(ans)'] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s055139964', 's414091740', 's742569997'] | [9004.0, 8944.0, 9052.0] | [24.0, 27.0, 29.0] | [113, 114, 66] |
p02582 | u857673087 | 2,000 | 1,048,576 | 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. | ["s = input()\n\nif 'SSS' in s:\n print(3)\nelif 'SS' in s:\n print(2)\nelif 'S' in s:\n print(1)\nelse:\n print(0)", "s = input()\n\nif 'RRR' in s:\n print(3)\nelif 'RR' in s:\n print(2)\nelif 'R' in s:\n print(1)\nelse:\n print(0)\n"] | ['Wrong Answer', 'Accepted'] | ['s175687791', 's966639046'] | [8944.0, 9044.0] | [24.0, 31.0] | [108, 109] |
p02582 | u859885477 | 2,000 | 1,048,576 | 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. | ["r = 0\nif 'r' not in s:\n print(0)\nelse:\n for i in range(len(s)):\n if s[i] == 'r' and i!=len(s)-1:\n for j in range(i+1,len(s)):\n if s[j] != 'r':\n break\n r = j-i\n print(r)\n ", "import re\nr = 0\ns = input()\nif 'r' not in s:\n print(0)\nelse:\n x = re.findall('r+',s)\n if len(x) == 2:\n print(1)\n else:\n print(len(x[0]))", "import re\nr = 0\ns = input()\nif 'R' not in s:\n print(0)\nelse:\n x = re.findall('R+',s)\n if len(x) == 2:\n print(1)\n else:\n print(len(x[0]))\n \n"] | ['Runtime Error', 'Wrong Answer', 'Accepted'] | ['s614358587', 's875750324', 's668876842'] | [8940.0, 9856.0, 9768.0] | [23.0, 38.0, 35.0] | [203, 150, 158] |
p02582 | u863723142 | 2,000 | 1,048,576 | 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. | ['input_line = input()\n#print(input_line)\ncharlist = list(input_line)\nindex = 0\nfor i in range(3):\n if(charlist[i]=="R"):\n index += 1\n \nif index==2:\n if charlist[1]=="S":\n print(1)\n \nelse:\n print(index)', 'input_line = input()\n#print(input_line)\ncharlist = list(input_line)\nindex = 0\nfor i in range(3):\n if(charlist[i]=="R"):\n index += 1\n \nif index==2:\n if charlist[1]=="S":\n print(1)\n \n else:\n print(index)\n \nelse:\n print(index)'] | ['Wrong Answer', 'Accepted'] | ['s892186776', 's438370037'] | [9020.0, 9016.0] | [27.0, 25.0] | [233, 273] |
p02582 | u863850961 | 2,000 | 1,048,576 | 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. | ['\ns=input()\nlist_s=list(s)\nelement="R"\ncount=0\nfor i in range(0,len(list_s)-1):\n if(list_s[i] in element):\n if(list_s[i+1] in element):\n count+=2\n else:\n count+=1\n else:\n count+=0\nprint(count)\n ', '# cook your dish here\ns=input()\nlist_s=list(s)\nelement="R"\ncount=0\nfor i in range(0,len(list_s)-1):\n if(element == list_s[i]):\n if(element == list_s[i+1]):\n count+=1\n \n else:\n count+=0\n\nprint(count)\n ', '\ns=input()\nlist_s=list(s)\nelement="R"\ncount=0\nfor i in range(0,len(list_s)-1):\n if(list_s[i] in element):\n if(list_s[i+1] in element):\n count+=2\n else:\n count+=1\n else:\n count+=0\nprint(count)\n ', '\ns=input()\nlist_s=list(s)\nelement="R"\ncount=0\nfor i in range(0,len(list_s)-1):\n if(list_s[i] in element):\n if(list_s[i+1] in element):\n count+=2\n else:\n count+=1\n else:\n count+=0\n\nprint(count)\n ', '\ns=input()\nlist_s=list(s)\nelement="R"\ncount=0\nfor i in range(0,len(list_s)-1):\n if(list_s[i] in element):\n if(list_s[i+1] in element):\n count+=2\n else:\n count+=1\n else:\n count+=1\n\nprint(count)\n ', "a = input()\nans2 = 0\nmax1= 0\nfor i in range(3):\n if a[i] == 'R':\n ans2 += 1\n else:\n max1= max(ans2, max1)\n ans2 = 0\nprint(max(ans2, max1))\n"] | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s277930878', 's459137852', 's673734379', 's860305201', 's933844094', 's007080893'] | [8884.0, 9048.0, 8988.0, 8788.0, 9060.0, 9024.0] | [31.0, 28.0, 32.0, 28.0, 24.0, 25.0] | [249, 245, 249, 250, 250, 166] |
p02582 | u869265610 | 2,000 | 1,048,576 | 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. | ["s=input()\nans=0\nc=0\nfor i in range(3):\n if s[i]=='R':\n ans+=1\n else:\n c=max(ans,c)\n ans=0\nprint(c)\n ", 'S=input()\nans=0\nc=0\nfor i in range(3):\n if S[i]=="R":\n ans+=1\n else:\n c=max(ans,c)\n ans=0\nprint(max(c,ans))\n'] | ['Runtime Error', 'Accepted'] | ['s949999347', 's751607860'] | [9004.0, 9028.0] | [23.0, 25.0] | [146, 119] |
p02582 | u869448801 | 2,000 | 1,048,576 | 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. | ["r = input()\nif r == 'RRR':\n print(3)\nelif r == 'RRS' or r == 'SRR':\n print(2)\nelif r == 'RSR' or r == 'RSS' or r =='SSR' or r =='SRS':\n print(1)\nelse rainy_days == 'SSS':\n print(0)\n", "rainy_days = input()\nif rainy_days == 'RRR':\n print(3)\nelif rainy_days == 'RRS' or 'SRR':\n print(2)\nelif rainy_days == 'RSR' or 'RSS' or 'SSR' or 'SRS':\n print(1)\nelse rainy_days == 'SSS':\n print(0)\n", 'rainy_days = input()\nif rainy_days = RRR:\n print(3)\nelif rainy_days == RRS or SRR:\n print(2)\nelif rainy_days == RSR or RSS or SSR or SRS:\n print(1)\nelif rainy_days == SSS:\n print(0)', "rainy_days = input()\nif rainy_days = 'RRR':\n print(3)\nelif rainy_days == 'RRS' or 'SRR':\n print(2)\nelif rainy_days == 'RSR' or 'RSS' or 'SSR' or 'SRS':\n print(1)\nelse rainy_days == 'SSS':\n print(0)", "rainy_days = input()\nif rainy_days = 'RRR':\n print(3)\nelif rainy_days == 'RRS' or 'SRR':\n print(2)\nelif rainy_days == 'RSR' or 'RSS' or 'SSR' or 'SRS':\n print(1)\nelif rainy_days == 'SSS':\n print(0)", "rainy_days = input('3日間で連続した雨の日は?:')\nif rainy_days = RRR:\n print(3)\nelif rainy_days == RRS or SRR:\n print(2)\nelif rainy_days == RSR or RSS or SSR or SRS:\n print(1)\nelif rainy_days == SSS:\n print(0)", "rainy_days = input('3日間で連続した雨の日は?:')\nif rainy_days = rrr:\n print(3)\nelif rainy_days == rrs or srr:\n print(2)\nelif rainy_days == rsr or rss or ssr or srs:\n print(1)\nelif rainy_days == sss:\n print(0)\n", "rainy_days = input()\nif rainy_days == 'RRR':\n print(3)\n", "r = input()\nif r == 'RRR':\n print(3)\nelif r == 'RRS' or r == 'SRR':\n print(2)\nelif r == 'RSR' or r == 'RSS' or r =='SSR' or r =='SRS':\n print(1)\nelif r == 'SSS':\n print(0)\n"] | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Accepted'] | ['s184316520', 's323923599', 's390258134', 's469067141', 's541432779', 's768916792', 's820879500', 's912906236', 's404205816'] | [8888.0, 8932.0, 8924.0, 9000.0, 8840.0, 8940.0, 8940.0, 9028.0, 8948.0] | [28.0, 24.0, 23.0, 27.0, 24.0, 25.0, 22.0, 23.0, 24.0] | [193, 211, 193, 209, 209, 233, 234, 58, 184] |
p02582 | u879866069 | 2,000 | 1,048,576 | 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. | ['S = input()\ncounts = [0]\nif "R" in S:\n counts.appned(1)\nif "RR" in S:\n counts.append(2)\nif "RRR" in S:\n counts.append(3)\nprint(max(counts))', 'S = input()\ncounts = [0]\nif "R" in S:\n counts.append(1)\nif "RR" in S:\n counts.append(2)\nif "RRR" in S:\n counts.append(3)\nprint(max(counts))'] | ['Runtime Error', 'Accepted'] | ['s891816632', 's560967833'] | [8960.0, 9092.0] | [21.0, 33.0] | [142, 142] |
p02582 | u883237011 | 2,000 | 1,048,576 | 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. | ["weather = input()\n\nraining = False\ncount = 0\nmax = 0\nfor w in weather:\n if w == 'R':\n if not raining:\n raining = True\n count = 1\n else:\n count += 1\n if max < count:\n max = count\n elif w == 'S':\n raining = False\n count = 0", "weather = input()\n\nraining = False\ncount = 0\nmax = 0\nfor w in weather:\n if w == 'R':\n if not raining:\n raining = True\n count = 1\n else:\n count += 1\n elif w == 'S':\n raining = False\n count = 0\n if max < count:\n max = count\n\nprint(max)"] | ['Wrong Answer', 'Accepted'] | ['s466287965', 's050540508'] | [9072.0, 9108.0] | [28.0, 32.0] | [306, 310] |
p02582 | u886545507 | 2,000 | 1,048,576 | 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. | ['#abc175b\nn=int(input())\nl=list(map(int,input().split()))\nl.sort()\ncnt=0\nfor i in range(n):\n for j in range(i):\n for k in range(j):\n if l[k]!=l[j] and l[i]!=l[j] and l[k]+l[j]>l[i]:\n cnt+=1\nprint(cnt)\n', "#abc17a\ns=input()\nif 'RRR' in s:\n print(3)\nelif 'RR' in s:\n print(2)\nelif 'R' in s:\n print(1)\nelse:\n print(0)\n"] | ['Runtime Error', 'Accepted'] | ['s089216385', 's134163884'] | [9112.0, 9028.0] | [22.0, 27.0] | [206, 110] |
p02582 | u887080361 | 2,000 | 1,048,576 | 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. | ['from numba import jit\n@jit\ndef main():\n n,k = map(int,input().split())\n p = list(map(int,input().split()))\n c = list(map(int,input().split()))\n\n ans=-10**18\n for i in range(n):\n start,count=i,1\n val=c[start]\n while p[start]-1 != i:\n start = p[start]-1\n count += 1\n val += c[start]\n start = i\n if val > 0:\n a = (k//count-1)*val\n ans=max(a,ans)\n num=count+k%count\n else:\n a=0\n num=min(k,count)\n for _ in range(num):\n a += c[start]\n start=p[start]-1\n ans=max(a,ans)\n print(ans)\nmain()', 's=list(input())\ncount=0\nfor d in s:\n if d=="R":\n count += 1\nif count == 2:\n if s[1]=="S":\n print(1)\n else:\n print(2)\nelse:\n print(count)'] | ['Runtime Error', 'Accepted'] | ['s637169342', 's558108068'] | [115692.0, 8968.0] | [742.0, 27.0] | [669, 169] |
p02582 | u888582202 | 2,000 | 1,048,576 | 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. | ['x,k,d= map(int,input().split())\nx=abs(x)\nif x>d*k:\n print(x-d*k)\nelse:\n m=x//d\n k=(k-m)%2\n print(abs((x%d)-k*d))', 'x,k,d= map(int,input().split())\ns=[]\nx=abs(x)\nif x>d*k:\n print(x-d*k)\nelse:\n for i in range(k):\n s.append(abs(x-d*i))\n s.sort()\n print(s[0])', "s=input()\n\ndef solution(s):\n if 'RRR' in s:\n return 3\n elif 'RR' in s:\n return 2\n elif 'R' in s:\n return 1\n else:\n return 0\nprint(solution(s))"] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s256208855', 's716814890', 's724348776'] | [9172.0, 9172.0, 9016.0] | [25.0, 21.0, 31.0] | [116, 149, 158] |
p02582 | u888804711 | 2,000 | 1,048,576 | 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. | ['R, C, K = map(int, input().split(" "))\nboard = [ [0]*(C+1) for _ in range(R+1) ]\nfor _ in range(K) :\n i, j, v = map(int, input().split(" "))\n board[i][j] = v\n\nscore = [ [ [0]*4 for _ in range(C+1) ] for _ in range(R+1) ] \n\nfor i in range(1, R+1) :\n for j in range(1, C+1) : \n if board[i][j] == 0 :\n for k in range(4) :\n score[i][j][k] = score[i][j-1][k] \n else :\n for k in range(3):\n score[i][j][k+1] = score[i][j-1][k] + board[i][j]\n \n descent = max(score[i-1][j])\n score[i][j][1] = max(descent + board[i][j], score[i][j-1][1], score[i][j-1][0]+board[i][j])\n score[i][j][0] = max(descent, score[i][j-1][0])\n\n\n\nprint(max(score[-1][-1]))\n', 's = input()\nprev = "R"\nres = 0\na = 0\nfor c in s :\n if c=="R" :\n a+=1\n else :\n a = 0\n res = max(res, a)\nprint(res)'] | ['Runtime Error', 'Accepted'] | ['s982091123', 's540905197'] | [9208.0, 9096.0] | [31.0, 28.0] | [743, 136] |
p02582 | u889541209 | 2,000 | 1,048,576 | 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. | ['S = input()\ncount = 0\nfor i in range(3):\n if S[i] == "R":\n count += 1\n else:\n count = 0\nprint(count)', 'S = input("S:")\ncount = 0\nfor i in range(3):\n if S[i] == "R":\n count += 1\n else:\n count = 0\nprint(count)', 'S = input()\ncount = 0\nif S[0] == "R" and S[1] == "R":\n if S[2] == "R":\n count = 3\n else:\n count = 2\nif S[0] == "R" and S[1] == "S":\n count = 1\nif S[0] == "S" and S[1] == "R":\n if S[2] == "R":\n count = 2\n else:\n count = 1\nif S[0] == "S" and S[1] == "S":\n if S[2] == "R":\n count = 1\n else:\n count = 0\nprint(count)\n'] | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s122497894', 's386461333', 's643607197'] | [8916.0, 9092.0, 9124.0] | [25.0, 31.0, 29.0] | [120, 124, 375] |
p02582 | u892340697 | 2,000 | 1,048,576 | 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. | ['s = input()\n\nans = 0\nif s == "SSS":\n print(3)\nelif "SS" in s:\n print(2)\nelif "S" in s:\n print(1)\nelse:\n print(0)', 's = input()\n\nans = 0\nif s == "RRR":\n print(3)\nelif "RR" in s:\n print(2)\nelif "R" in s:\n print(1)\nelse:\n print(0)'] | ['Wrong Answer', 'Accepted'] | ['s681880899', 's816539331'] | [8912.0, 9064.0] | [30.0, 31.0] | [124, 124] |
p02582 | u893661063 | 2,000 | 1,048,576 | 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. | ['a = input()\n\nif a.count("SSS") == 1:\n print (3)\nelif a.count("SS") == 1:\n print (2)\nelif a.count("S") == 1:\n print (1)\nelif a.count("S") == 2:\n print (1)\nelse:\n print (0)\n', 'a = input()\n\nif a.count("RRR") == 1:\n print (3)\nelif a.count("RR") == 1:\n print (2)\nelif a.count("R") == 1:\n print (1)\nelif a.count("R") == 2:\n print (1)\nelse:\n print (0)\n'] | ['Wrong Answer', 'Accepted'] | ['s568631749', 's499652833'] | [9100.0, 9032.0] | [26.0, 27.0] | [186, 186] |
p02582 | u894433559 | 2,000 | 1,048,576 | 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. | ["s = rawinput()\nres = 0\ncur = 0\nfor i in s:\n if i =='S':\n cur = 0\n else:\n cur += 1\n res = max(cur, res)\nprint(res)", "s = input()\nres = 0\ncur = 0\nfor i in s:\n if i =='S':\n cur = 0\n else:\n cur += 1\n res = max(cur, res)\nprint(res)"] | ['Runtime Error', 'Accepted'] | ['s588653120', 's269650775'] | [9040.0, 9012.0] | [31.0, 27.0] | [122, 119] |
p02582 | u894529060 | 2,000 | 1,048,576 | 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. | ['temp = input()\n\nS = list(temp)\n\ncnt=0\ntmp_s = ""\nfor i,s in enumerate(S,start=1):\n if i == 1:\n cnt=cnt + 1\n tmp_s = s\n continue\n\n if tmp_s == s:\n cnt = cnt + 1\n else:\n tmp_s = s\n cnt=1\n \nprint(cnt)', '#!/usr/bin/env python3\n# coding:utf-8\n\ntemp = input()\n\nS = list(temp)\n\ncnt=0\nmax_cnt=0\ntmp_s = ""\nflag=0\n\ncnt = S.count(\'R\')\nif cnt == 2:\n if S[1] == \'S\':\n cnt=1\n\nprint(cnt)'] | ['Wrong Answer', 'Accepted'] | ['s782089020', 's227894716'] | [8968.0, 9016.0] | [33.0, 31.0] | [221, 183] |
p02582 | u898967808 | 2,000 | 1,048,576 | 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. | ["s = input()\nans = s.count('R')\nif s=='RSR':\n ans = 1\nprint(1) \n ", "s = input()\nans = s.count('R')\nif s=='RSR':\n ans = 1\nprint(ans)"] | ['Wrong Answer', 'Accepted'] | ['s726179997', 's082833099'] | [8972.0, 9016.0] | [32.0, 24.0] | [67, 64] |
p02582 | u911516631 | 2,000 | 1,048,576 | 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. | ['S = input()\nif S == "RRR":\n print(3)\nelif S in "RR":\n print(2)\nelif S in "R":\n print(1)\nelse:\n print(0)', 'S = input()\nif S == "RRR":\n print(3)\nelif "RR" in S:\n print(2)\nelif "R" in S:\n print(1)\nelse:\n print(0)'] | ['Wrong Answer', 'Accepted'] | ['s582108310', 's611271034'] | [8984.0, 9024.0] | [33.0, 25.0] | [115, 115] |
p02582 | u912199642 | 2,000 | 1,048,576 | 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. | ["X, K, D = [int(i) for i in input().strip().split(' ')]\n\ntmp = X // D\nd1 = X - (D * tmp)\nd2 = X - (D * (tmp + 1))\n\nif tmp >= K:\n ans = X - (D * K)\nelse:\n if (tmp % 2) ^ (K % 2) == 0:\n ans = d1\n else:\n ans = d2\n\nprint(abs(ans))\n", "S = input().strip()\nprint(max([len(i) for i in S.split('S')]))\n"] | ['Runtime Error', 'Accepted'] | ['s045270028', 's285415763'] | [9148.0, 8944.0] | [25.0, 30.0] | [235, 63] |
p02582 | u912330011 | 2,000 | 1,048,576 | 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. | ["max([len(t) for t in input().split('S')])", "print(max([len(t) for t in input().split('S')]))\n"] | ['Wrong Answer', 'Accepted'] | ['s247538443', 's169077395'] | [9044.0, 9028.0] | [32.0, 32.0] | [41, 49] |
p02582 | u916338311 | 2,000 | 1,048,576 | 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. | ['a, b, c = input()\n\nif b == "R":\n d = 1\n if a == "R":\n d += 1\n if c == "R":\n \td += 1\nelse:\n d = 0\n if a == "R" or c == "R":\n d += 1\n \nprint(c)', 'l = [e in e in input().split()]\nc = 0\nif l[1] == "R":\n c += 1\n if l[0] == "R":\n c += 1\n if l[2] == "R":\n \tc += 1\nelse:\n if l[0] == 1 or l[2] == "R":\n c += 1\n\nprint(c)\n', 'a, b, c = input()\n\nif b == "R":\n d = 1\n if a == "R":\n d += 1\n if c == "R":\n \td += 1\nelse:\n d = 0\n if a == "R" or c == "R":\n d += 1\n \nprint(d)'] | ['Wrong Answer', 'Runtime Error', 'Accepted'] | ['s142030595', 's534634251', 's900868739'] | [8960.0, 9096.0, 9024.0] | [27.0, 34.0, 29.0] | [153, 178, 153] |
p02582 | u917558625 | 2,000 | 1,048,576 | 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. | ["S=input()\nif S=='SSS':\n print(3)\nelif S==('SSR' or 'RSS'):\n print(2)\nelif S=='RRR':\n print(0)\nelse:\n print(1)", "S=input()\nif S=='RRR':\n print(3)\nelif S=='RRS' or S=='SRR':\n print(2)\nelif S=='SSS':\n print(0)\nelse:\n print(1)"] | ['Wrong Answer', 'Accepted'] | ['s632156410', 's850120311'] | [8972.0, 9036.0] | [24.0, 28.0] | [113, 114] |
p02582 | u917642744 | 2,000 | 1,048,576 | 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. | ["a=input()\ndef fun(a):\n count=0\n max=0\n for i in a:\n if i=='R':\n count+=1\n \n if count>=max:\n max=count\n \n else:\n if count>=max:\n max=count\n count=0\n return max\n \n ", "def fun(a):\n count=0\n max=0\n for i in a:\n if i=='R':\n count+=1\n \n if count>=max:\n max=count\n \n else:\n if count>=max:\n max=count\n count=0\n return max\n \n ", "a=input()\ncount=0\nmax=0\nfor i in a:\n if i=='R':\n count+=1\n if count>=max:\n max=count \n else:\n if count>=max:\n max=count\n count=0\nprint(max) \n "] | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s865907308', 's945391849', 's375687341'] | [9036.0, 9056.0, 8992.0] | [31.0, 25.0, 28.0] | [267, 257, 212] |
p02582 | u919681556 | 2,000 | 1,048,576 | 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. | ['S = input()\nif S.contains("RRR"):\n print("3")\nelif S.contains("RR"):\n print("2")\nelif S.contains("R"):\n print("1")\nelse:\n print("0")', "s = input().upper()\nif s.count('RRR') == 1:\n print(3)\nelif s.count('RR') == 1:\n print(2)\nelif s.count('R') > 0:\n print(1)\nelse:\n print(0)"] | ['Runtime Error', 'Accepted'] | ['s198302156', 's333672099'] | [9028.0, 9036.0] | [24.0, 29.0] | [144, 141] |
p02582 | u929793345 | 2,000 | 1,048,576 | 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. | ["s = input()\ns = s.split('S')\nprint(max(len(s)))", "s = input()\n\nif s.count('R') == 2:\n print(s.count('RR'+1)\nelse:\n print(s.count('R')", "s = input()\n\nif s.count('R') == 2:\n print(s.count('RR')+1)\nelse:\n print(s.count('R'))"] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s105316563', 's232497173', 's814032973'] | [8888.0, 8996.0, 8964.0] | [23.0, 24.0, 25.0] | [47, 85, 91] |
p02582 | u929996201 | 2,000 | 1,048,576 | 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. | ["Word = input()\n\ncounter=0\n\nfor i in range(len(Word)):\n if 'R'==Word[i]:\n counter +=1\n else:\n counter=0\nprint(counter)", "Word = input()\n\ncounter=0\nmaxc = 0\n\nfor i in range(len(Word)):\n if 'R'==Word[i]:\n counter +=1\n maxc = max(counter, maxc)\n else:\n counter=0\nprint(maxc)"] | ['Wrong Answer', 'Accepted'] | ['s106823226', 's812001791'] | [9036.0, 9032.0] | [28.0, 31.0] | [137, 177] |
p02582 | u933650305 | 2,000 | 1,048,576 | 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. | ['x,k,d=map(int,input().split())\na=divmod(abs(x),d) \nif a[0]<k:\n if a[1]==0 and a[0]%2==1:\n print(d)\n elif a[1]==0 and a[0]%2==0:\n print(0)\n elif a[1]!=0 and a[0]%2!=0:\n if x<0:\n print(d-a[1])\n else:\n print(abs(a[1]-d))\n else:\n print(a[1])\nelse:\n print(abs(x)-d*k)\n', 'N=input()\nif N=="RRR":\n print(3)\nelif N=="SRR" or N=="RRS":\n print(2)\nelif N=="SSR" or N=="RSR" or N=="SRS" or N=="RSS":\n print(1)\nelse:\n print(0)\n'] | ['Runtime Error', 'Accepted'] | ['s933591406', 's006144205'] | [9204.0, 9092.0] | [28.0, 32.0] | [294, 151] |
p02582 | u934052933 | 2,000 | 1,048,576 | 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. | ['\ndef main():\n x, k, d = map(int, input().split())\n # x > 0\n if x < 0:\n x = -1 * x\n #the number of d in x\n r = abs(x) // d\n k_rest = k - r\n if r > 0 and k_rest < 0:\n print(x - k * d)\n exit()\n\n x_r = x - d * r\n x_l = x_r - d\n\n # print(f"xr: {x_r}\\nxl: {x_l}\\nk: {k_rest}")\n\n if k_rest % 2 == 0:\n print(abs(x_r))\n else:\n print(abs(x_l))\n\nif __name__ == "__main__":\n main()\n', 'def main():\n s = input()\n if s == "RSR":\n print(1)\n else:\n cnt = 0\n for i in s:\n if i == "R":\n cnt += 1\n\n print(cnt)\n \nif __name__ == "__main__":\n main()'] | ['Runtime Error', 'Accepted'] | ['s267549142', 's436155253'] | [9124.0, 9100.0] | [27.0, 29.0] | [444, 222] |
p02582 | u938785734 | 2,000 | 1,048,576 | 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. | ["s=input()\nc=0\nmc=0\nfor i in s:\n if i='R':\n c+=1\n mc=c\n else:\n c=0\nprint(max(c,mc))", "s=input()\nc=0\nmc=0\nfor i in s:\n if i=='R':\n c+=1\n mc=c\n else:\n c=0\nprint(max(c,mc))\n"] | ['Runtime Error', 'Accepted'] | ['s906739941', 's691686051'] | [9012.0, 8972.0] | [30.0, 28.0] | [93, 95] |
p02582 | u940592576 | 2,000 | 1,048,576 | 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. | ["s=[str(i) for i in input()]\nif str[0]=='R' and str[1]=='S':\n\tprint(1)\nelif str[1]=='S' and str[2]=='R':\n\tprint(1)\nelif str[0]=='S' and str[1]=='R' and str[2]=='S':\n\tprint(1)\nelif str[0]=='R' and str[1]=='R' and str[2]=='S':\n\tprint(2)\nelif str[0]=='S' and str[1]=='R' and str[2]=='R':\n\tprint(2)\nelif str[0]=='R' and str[1]=='R' and str[2]=='R':\n\tprint(3)\nelse:\n\tprint(0)", "s=[str(i) for i in input()]\nif s[0]=='R' and s[1]=='S':\n\tprint(1)\nelif s[1]=='S' and s[2]=='R':\n\tprint(1)\nelif s[0]=='S' and s[1]=='R' and s[2]=='S':\n\tprint(1)\nelif s[0]=='R' and s[1]=='R' and s[2]=='S':\n\tprint(2)\nelif s[0]=='S' and s[1]=='R' and s[2]=='R':\n\tprint(2)\nelif s[0]=='R' and s[1]=='R' and s[2]=='R':\n\tprint(3)\nelse:\n\tprint(0)"] | ['Runtime Error', 'Accepted'] | ['s272437462', 's700766883'] | [9132.0, 8976.0] | [22.0, 28.0] | [369, 337] |
p02582 | u943371421 | 2,000 | 1,048,576 | 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. | ["print(input().count('S'))", "s = input()\nif s == 'RRR':\n print(3)\nelif s == 'RRS' or s == 'SRR':\n print(2)\nelif s == 'SSS':\n print(0)\nelse:\n print(1)\n"] | ['Wrong Answer', 'Accepted'] | ['s152612288', 's557119816'] | [9080.0, 9020.0] | [27.0, 24.0] | [25, 133] |
p02582 | u945065638 | 2,000 | 1,048,576 | 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. | ['n = int(input())\nl = list(map(int,input().split()))\n\nans = 0\n\nl.sort()\n\nfor i in range(n) :\n for j in range(i+1,n):\n for k in range(j+1,n):\n if l[i] != l[j] != l[k] and l[i] < l[j] < l[k]:\n ans += 1\n\nprint(ans)', "s = input()\n\nthree ='RRR'\ntwo ='RR'\none ='R'\n\nif three in s:\n print('3')\nelif two in s:\n print('2')\nelif one in s:\n print('1')\n \nelse :\n print('0')"] | ['Runtime Error', 'Accepted'] | ['s981608120', 's317252669'] | [9136.0, 9108.0] | [28.0, 24.0] | [251, 163] |
p02582 | u945472874 | 2,000 | 1,048,576 | 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. | ['S = input()\nif ("RRR" in S):\n return 3\nelif ("RR" in S):\n return 2\nelif ("R" in S):\n return 1\nelse:\n return 0\n', 'if ("RRR" in S):\n return 3\nelif ("RR" in S):\n return 2\nelif ("R" in S):\n return 1\nelse:\n return 0', 'if ("RRR" in S):\n print(3)\nelif ("RR" in S):\n print(2)\nelif ("R" in S):\n print(1)\nelse:\n print(0)\n', 'print("Hello")', 'S = input()\nif ("RRR" in S):\n print(3)\nelif ("RR" in S):\n print(2)\nelif ("R" in S):\n print(1)\nelse:\n print(0)\n'] | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Accepted'] | ['s224967022', 's351816975', 's473787374', 's969972460', 's987872607'] | [8868.0, 9032.0, 9076.0, 8964.0, 9036.0] | [25.0, 24.0, 20.0, 27.0, 27.0] | [114, 101, 102, 14, 114] |
p02582 | u948875995 | 2,000 | 1,048,576 | 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. | ['A = input()\nb = A.count("RRR")\nC = A.count("RR")\nD = A.count("R")\nif b == 1: \n print(3)\nelif C ==1:\n print(2)\nelse:\n if D >0:\n print(1)\n else:', 'A = input()\nb = A.count("SSS")\nC = A.count("SS")\nD = A.count("S")\nif b == 1: \n print(3)\nelif C ==1:\n print(2)\nelse:\n if D ==1:\n print(1)\n else:\n print(0)', 'A = input()\nb = A.count("RRR")\nC = A.count("RR")\nif b == 1: \n print(3)\nelif C ==1:\n print(2)\nelse:\n if A.count("R")>0:\n print(1)\n else:\n print(0)'] | ['Runtime Error', 'Wrong Answer', 'Accepted'] | ['s653230677', 's898349928', 's813941471'] | [8836.0, 9036.0, 8996.0] | [21.0, 29.0, 29.0] | [155, 171, 163] |
p02582 | u949315872 | 2,000 | 1,048,576 | 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. | ['S = input()\n\nif S == "RRR":\n print("3")\nif S == "SRR":\n print("2")\nif S == "RRS":\n print("2")\nif S == "SSS":\n print("0")\nelse:\n print("1")', 'S = input()\n\nif S == "RRR":\n print("3")\nif S == "SRR":\n print("2")\nif S == "RRS":\n print("2")\nif S == "SSS":\n print("0")\nif S == "SSR":\n print("1")\nif S == "SRS":\n print("1")\nif S == "RSS":\n print("1")\nif S == "RSR":\n print("1")'] | ['Wrong Answer', 'Accepted'] | ['s473068700', 's796541608'] | [9032.0, 9112.0] | [29.0, 25.0] | [143, 236] |
p02582 | u956268964 | 2,000 | 1,048,576 | 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. | ["S = input()\n\nfor i in S:\n if i != 'R':\n count = 0\n else:\n count = count + 1\n \n if max_c < count:\n max_c = count\n \nprint(max_c)", "S = input()\nmax_c = 0\nfor i in S:\n if i != 'R':\n count = 0\n else:\n count = count + 1\n \n if max_c < count:\n max_c = count\n \nprint(max_c)", "S = input()\ncount = 0\nmax_c = 0\n\nfor i in S:\n if i != 'R':\n count = 0\n else:\n count = count + 1\n \n if max_c < count:\n max_c = count\n \nprint(max_c)"] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s120150239', 's764944586', 's571429552'] | [8880.0, 8940.0, 9000.0] | [29.0, 27.0, 29.0] | [162, 171, 182] |
p02582 | u957872856 | 2,000 | 1,048,576 | 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. | ['S = input()\ncnt = 0\nif S.count("S") == 3:\n cnt = 3\nelif S.count("S") == 1:\n cnt = 1\nelif S.count("S") == 0:\n cnt = 0\nelse:\n if (S[0] == "S" and S[1] == "S") or (S[1] == "S" and S[2] == "S"):\n cnt = 2\n else:\n cnt = 1\nprint(cnt)', 'S = input()\ncnt = 0\nif S.count("R") == 3:\n cnt = 3\nelif S.count("R") == 1:\n cnt = 1\nelif S.count("R") == 0:\n cnt = 0\nelse:\n if (S[0] == "R" and S[1] == "R") or (S[1] == "R" and S[2] == "R"):\n cnt = 2\n else:\n cnt = 1\nprint(cnt)'] | ['Wrong Answer', 'Accepted'] | ['s727478795', 's116444799'] | [9124.0, 9044.0] | [29.0, 26.0] | [237, 237] |
p02582 | u962765087 | 2,000 | 1,048,576 | 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. | ["L = [s for s in input()]\nif not 'R' in L:\n print(0)\nelif not 'S' in L:\n print(3)\nelif L[1] == 'S':\n if 'R' in L :\n print(1)\nelif L[0] == 'S'\n print(1)\nelse:\n print(2)\n ", "L = [s for s in input()]\nif not 'R' in L:\n print(0)\nelif not 'S' in L:\n print(3)\nelif L[2] == 'S':\n if 'R' in L :\n print(1)\nelse:\n print(2)", "L = [s for s in input()]\nif not 'R' in L:\n print(0)\nelif not 'S' in L:\n print(3)\nelif L[1] == 'S':\n if 'R' in L :\n print(1)\nelif L[0] == 'S':\n if L[2] =='S':\n print(1)\n else:\n print(2)\nelse:\n print(2)\n "] | ['Runtime Error', 'Wrong Answer', 'Accepted'] | ['s097475123', 's748229348', 's978981810'] | [8964.0, 9100.0, 8972.0] | [26.0, 30.0, 25.0] | [177, 146, 218] |
p02582 | u966542724 | 2,000 | 1,048,576 | 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. | ["a = input()\nc = 0\nans = 0\nfor s in a:\n if s == 'S':\n c += 1\n else:\n c = 0\n ans = max(ans,c)\n\nprint(ans)", "a = input()\nc = 0\nans = 0\nfor s in a:\n if s == 'R':\n c += 1\n else:\n c = 0\n ans = max(ans,c)\n\nprint(ans)"] | ['Wrong Answer', 'Accepted'] | ['s958254108', 's042144259'] | [8624.0, 9092.0] | [30.0, 29.0] | [126, 126] |
p02582 | u969618034 | 2,000 | 1,048,576 | 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. | ["a=input()\nmax=[]\nfor i in range(3):\n if a[i]== 'R':\n if i ==0:\n max[0]=1\n else:\n max[i]=max[i-1]+1\n else:\n max[i]=0\nprint(sum(max))\n ", "a=input()\nmax=[0]*4\nfor i in range(3):\n if a[i]== 'R':\n if i ==0:\n max[0]=1\n else:\n max[i]=max[i-1]+1\n else:\n max[i]=0\nprint(max)\n ", "a=input()\nf=[0]*3\nfor i in range(3):\n if a[i]== 'R':\n if i ==0:\n f[0]=1\n else:\n f[i]=f[i-1]+1\n else:\n f[i]=0\nprint(max(f))"] | ['Runtime Error', 'Wrong Answer', 'Accepted'] | ['s425981326', 's595345402', 's518709494'] | [8844.0, 8976.0, 9096.0] | [24.0, 32.0, 33.0] | [155, 153, 143] |
p02582 | u969708690 | 2,000 | 1,048,576 | 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. | ['import sympy', 'S=input()\nif S=="SSS":\n print(0)\nelif S=="RSR" or S=="RSS" or S=="SRS" or S=="SSR":\n print(1)\nelif S=="RRS" or S=="SRR":\n print(2)\nelse:\n print(3)'] | ['Runtime Error', 'Accepted'] | ['s937643158', 's050335495'] | [9068.0, 8920.0] | [24.0, 28.0] | [12, 150] |
p02582 | u970315942 | 2,000 | 1,048,576 | 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. | ["s = input()\nif 'SSS' in s:\n print(3)\nelif 'SS' in s:\n print(2)\nelif 'S' in s:\n print(1)\nelse:\n print(0)", "s = input()\nif 'RRR' in s:\n print(3)\nelif 'RR' in s:\n print(2)\nelif 'R' in s:\n print(1)\nelse:\n print(0)\n"] | ['Wrong Answer', 'Accepted'] | ['s934925697', 's866176008'] | [9028.0, 9024.0] | [32.0, 30.0] | [107, 108] |
p02582 | u972591645 | 2,000 | 1,048,576 | 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. | ["import re\ns = input()\nprint(max(map(len, re.split('R', s))))", "print(len(max((input().split('S')))))"] | ['Wrong Answer', 'Accepted'] | ['s541584994', 's263413647'] | [9852.0, 8976.0] | [38.0, 29.0] | [60, 37] |
p02582 | u972991614 | 2,000 | 1,048,576 | 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. | ["S = input()\nlist_s = list(S)\ncount = 0\nif len(list_s)<4:\n for i in range(3):\n if list_s[i] == 'R':\n count +=1\n elif list_s[i] == 'S':\n count = 0\nprint(count)", "S = input()\nlist_s = list(S)\ncount = 0\nfor i in range(3):\n if list_s[i] == 'R':\n count +=1\n elif list_s[i] == 'S':\n count = 0\nprint(count)", "S = input()\nif 1 <= len(S) <=3:\n list_s = list(S)\n count = 0\n i = 1\n while i <=3:\n if list_s[i-1] == 'R':\n count +=1\n elif list_s[i-1] == 'S':\n count = 0\n i +=1\nprint(count)", "S = input()\n list_s = list(S)\n count = 0\nif 1<len(list_s)<4\nfor i in range(2):\n if list_s[i] == 'R':\n count +=1\n elif list_s[i] == 'S':\n count = 0\nprint(count)", "S = input()\nif S<4:\n list_s = list(S)\n count = 0\n for i in range(3):\n if list_s[i] == 'R':\n count +=1\n elif list_s[i] == 'S':\n count = 0\n print(count)", "S = input()\nif 1< S <4:\n list_s = list(S)\n count = 0\n for i in range(3):\n if list_s[i] == 'R':\n count +=1\n elif list_s[i] == 'S':\n count = 0\n print(count)", '\nx,k,d = map(int,input().split())\nx = abs(x)\nif (x//d) >=k:\n ans = x - d*k\nelse:\n y = x-(x//d)*d\n if k- (x//d)%2 != 0:\n ans = y\n else:\n ans = y-d\nprint(abs(ans))', "S = input()\nlist_s = list(S)\ncount = 0\ni = 1\nwhile i <=3:\n if list_s[i-1] == 'R':\n count +=1\n elif list_s[i-1] == 'S':\n count = 0\n i +=1\nprint(count)", "S = input()\nlist_s = list(S)\ncount = 0\nfor i in range(3):\n if list_s[i] == 'R':\n count +=1\n elif list_s[i] == 'S':\n count = 0\nprint(count)", "S = input()\nlist_s = list(S)\ncount = 0\nx = []\nfor i in range(3):\n if list_s[i] == 'R':\n count +=1\n elif list_s[i] == 'S':\n x.append(count)\n count = 0\nx.append(count)\nprint(max(x))"] | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s102106673', 's109549754', 's113143581', 's538059586', 's789790182', 's856008339', 's865728866', 's874466476', 's925564979', 's572601806'] | [9100.0, 9096.0, 8976.0, 8936.0, 9104.0, 9056.0, 9172.0, 8992.0, 8964.0, 9108.0] | [30.0, 27.0, 33.0, 24.0, 28.0, 29.0, 20.0, 27.0, 34.0, 30.0] | [196, 158, 228, 185, 198, 202, 223, 172, 158, 206] |
p02582 | u973069173 | 2,000 | 1,048,576 | 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. | ["a = list(input())\nc = 0\nx = []\nfor i in a:\n print(i)\n if i == 'R':\n c += 1\n else:\n x.append(c)\n c = 0\n x.append(c)\nprint(max(x))", 'a = input()\nc = 0\nx = []\nfor i in a:\n\tif i == \'R\':\n\t\tc+=1\n\tif i == "S":\n\t\tx.append(c)\t\n \tc = 0\nprint(max(x))', "a = list(input())\nc = 0\nx = []\nfor i in a:\n \n if i == 'R':\n c += 1\n else:\n x.append(c)\n c = 0\n x.append(c)\nprint(max(x))"] | ['Wrong Answer', 'Runtime Error', 'Accepted'] | ['s788919149', 's805575002', 's909459572'] | [9040.0, 8936.0, 9116.0] | [29.0, 25.0, 30.0] | [161, 113, 153] |
p02582 | u977982384 | 2,000 | 1,048,576 | 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. | ['n = input()\na = list(map(int, input().split()))\n\nmin_value=100\n\nfor i in a:\n x = 0\n while i % 2 == 0:\n i //= 2\n x += 1\n if min_value > x:\n min_value = x\nprint(min_value)', "s = input()\nrecord = list(s)\nn = 0\nhigh_score = 0\nyesterday = ' '\nfor today in record :\n if today == 'R':\n if yesterday == 'R' :\n n += 1\n else :\n n = 1\n if high_score < n :\n high_score = n\n yesterday = today\nprint(high_score)\n"] | ['Runtime Error', 'Accepted'] | ['s966464312', 's301691949'] | [9040.0, 9040.0] | [26.0, 28.0] | [199, 278] |
p02582 | u978789527 | 2,000 | 1,048,576 | 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. | ["s = input()\nr = 3 if s == 'RRR' else r = 1\nif 'RR' in s:\n r = 2\nprint(r)", "s = input()\nr = 3 if s == 'RRR' else 1\nif 'RR' in s and s != 'RRR':\n r = 2\nelif not 'R' in s:\n r = 0\nprint(r)"] | ['Runtime Error', 'Accepted'] | ['s117707242', 's918093875'] | [9084.0, 9072.0] | [24.0, 28.0] | [73, 115] |
Subsets and Splits
No saved queries yet
Save your SQL queries to embed, download, and access them later. Queries will appear here once saved.