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
|
---|---|---|---|---|---|---|---|---|---|---|
p03288 | u783676040 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['N = int(input())\nif N < 1200:\n print("ABC")\nelif N < 2800:\n print("ARC")\nelse\n print("AGC")\n\n', 'N = int(input())\nif N < 1200:\n print("ABC")\nelif N < 2800:\n print("ARC")\nelse:\n print("AGC")'] | ['Runtime Error', 'Accepted'] | ['s882464727', 's083439441'] | [8976.0, 9148.0] | [24.0, 26.0] | [96, 95] |
p03288 | u790301364 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['def main18():\n strbuf = input(\'\');\n num = int(strbuf);\n if(num<1200):\n printf("ABC");\n elif(num<2800):\n printf("ARC");\n else:\n printf("AGC");\n\n\nif __name__ == \'__main__\':\n main18()', '\ndef main17():\n strbuf = "U"\n strbuf2 = "N"\n strbuf3 = "K"\n print(strbuf + strbuf2 + strbuf3)\n\ndef main18():\n strbuf = input(\'\');\n num = int(strbuf);\n if(num<1200):\n print("ABC");\n elif(num<2800):\n print("ARC");\n else:\n print("AGC");\n\n\nif __name__ == \'__main__\':\n main18()'] | ['Runtime Error', 'Accepted'] | ['s668399680', 's863097418'] | [3060.0, 3060.0] | [17.0, 19.0] | [219, 323] |
p03288 | u790877102 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["R = int(raw_input())\n\nif R <1200:\n\tprint('ABC')\nelif 1200<=R<2800:\n\tprint('ARC')\nelse :\n\tprint('AGC')", "R = int(input())\n\nif R <1200:\n\tprint('ABC')\n\nelif R<2800:\n\tprint('ARC')\n\nelse :\n\tprint('AGC')"] | ['Runtime Error', 'Accepted'] | ['s819376886', 's175612234'] | [2940.0, 2940.0] | [18.0, 17.0] | [101, 93] |
p03288 | u797016134 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['r = int(input())\nif r < 1200:\n print("ABC")\nif 1200 <= r < 2800:\n print("ARC")\nelse:\n print("AGC")', 'r = int(input())\nif r < 1200:\n print("ABC")\nif 1200 <= r < 2800:\n print("ARC")\nif 2800 <= r:\n print("AGC")'] | ['Wrong Answer', 'Accepted'] | ['s914244155', 's785184824'] | [2940.0, 2940.0] | [17.0, 19.0] | [107, 115] |
p03288 | u798181098 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["print'A%sC'%'BRG'[input()/100+4>>4]", "print('A'+'BRG'[int(input())//100+4>>4]+'C')"] | ['Runtime Error', 'Accepted'] | ['s078798100', 's796535607'] | [2940.0, 2940.0] | [17.0, 17.0] | [35, 44] |
p03288 | u798316285 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['r=int(input())\nprint("ABC" if r<1200 else "AGC" if r<2800)', 'r=int(input())\nprint("ABC" if r<1200 else "ARC" if r<2800 else "AGC")'] | ['Runtime Error', 'Accepted'] | ['s676477136', 's733331083'] | [2940.0, 2940.0] | [17.0, 17.0] | [58, 69] |
p03288 | u801274036 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["rate = int(input())\n\nif rate >= 0 && rate <= 1199:\n\tprint('ABC')\nelif rate >= 1200 && rate <= 2799:\n\tprint('ARC')\nelse:\n\tprint('AGC')\n", "rate = int(input())\n\nif rate >= 0 and rate <= 1199:\n\tprint('ABC')\nelif rate >= 1200 and rate <= 2799:\n\tprint('ARC')\nelse:\n\tprint('AGC')\n"] | ['Runtime Error', 'Accepted'] | ['s385613265', 's945609142'] | [2940.0, 2940.0] | [17.0, 17.0] | [134, 136] |
p03288 | u806855121 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["R = int(input())\n\nif R >= 2800:\n print('AGC')\nelif R < 1200:\n print('ABC')\nelse:a\n print('ARC') ", "R = int(input())\n\nif R >= 2800:\n print('AGC')\nelif R < 1200:\n print('ABC')\nelse:\n print('ARC') "] | ['Runtime Error', 'Accepted'] | ['s099299657', 's421485875'] | [2940.0, 2940.0] | [17.0, 17.0] | [105, 104] |
p03288 | u813174766 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['n=int(input())\nans=("ABC" if n<1200 else("ARC" if n<2800 else "AGC"))', 'n=int(input())\nprint("ABC" if n<1200 else("ARC" if n<2800 else "AGC"))'] | ['Wrong Answer', 'Accepted'] | ['s367883079', 's048727737'] | [3064.0, 2940.0] | [19.0, 17.0] | [69, 70] |
p03288 | u814986259 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['R = int(input())\nif R < 1200:\n print("ABC")\nelse:\n if R < 2800:\n print("ARC")\n else:\n print("AGC")\n ', 'R = int(input())\nif R < 1200:\n print("ABC")\nelse:\n if R < 2800:\n print("ARC")\n else:\n print("AGC")\n ', 'R = int(input())\nif R < 1200:\n print("ABC")\nelse:\n if R < 2800:\n print("ARC")\n else:\n print("AGC")\n '] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s089298599', 's946180909', 's671380597'] | [2940.0, 2940.0, 3060.0] | [17.0, 17.0, 19.0] | [112, 116, 110] |
p03288 | u832039789 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['r=input()\nif r<1200:\n print("ABC")\nelif r<2800:\n print("ARC")\nelse:\n print("AGC")', 'r=int(input())\nif r<1200:\n print("ABC")\nelif r<2800:\n print("ARC")\nelse:\n print("AGC")'] | ['Runtime Error', 'Accepted'] | ['s950095292', 's525719840'] | [2940.0, 2940.0] | [17.0, 17.0] | [84, 89] |
p03288 | u840958781 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['R=int(input())\nif R<1200:\n print(ABC)\nelif R<2800:\n print(ARC)\nelse:\n print(AGC)\n', 'R=int(input())\nif R<1200:\n print("ABC")\nelif R<2800:\n print("ARC")\nelse:\n print("AGC")\n'] | ['Runtime Error', 'Accepted'] | ['s198781942', 's763079887'] | [2940.0, 2940.0] | [17.0, 18.0] | [90, 96] |
p03288 | u843932857 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['s = input()\nif len(s) < 4:\n print(\'WA\')\n exit()\ncount = 0\nfor i in range(len(s)):\n if i == 0:\n if s[i] != \'A\':\n break\n elif i == 1:\n if s[i].islower():\n continue\n else:\n break\n elif i>1 and i < len(s)-1 :\n if s[i]==\'C\':\n if count == 0:\n count += 1\n continue\n else:\n break\n elif s[i].islower():\n continue\n else:\n break\n elif i == len(s) :\n if s[i].islower():\n print("AC")\n exit()\n else:\n break\nprint("WA")', 's = input()\ncount = 0\nfor i in range(len(s)):\n if i == 0:\n if s[i] != \'A\':\n break\n elif i == 1:\n if s[i].islower():\n pass\n else:\n break\n elif i>1 and i < len(s)-1 :\n if s[i]==\'C\':\n if count == 0:\n count += 1\n else:\n break\n elif s[i].islower():\n pass\n else:\n break\n elif i == len(s)-1 :\n if s[i].islower():\n print("AC")\n exit()\n else:\n break\nprint("WA")', 'r = int(input())\nif r < 1200:\n print("ABC")\nelif r < 2800:\n print("ARC")\nelse:\n print("AGC")\n'] | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s683277203', 's856086909', 's342423373'] | [3064.0, 3064.0, 2940.0] | [19.0, 17.0, 17.0] | [625, 552, 102] |
p03288 | u853185302 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["S = input()\nif S.startswith('A'):\n if S[2:-1].count('C') == 1:\n str = S[1] + S[2:-2].replace('C','c') + S[-1]\n if str.islower():\n print('AC')\nelse:\n print('WA')", "S = input()\nif S.startswith('A'):\n if S[2:-1].count('C') == 1:\n str = S[1] + S[2:-1].replace('C','c') + S[-1]\n if str.islower():\n print('AC')\nelse:\n print('WA')", "S = input()\nif S.startswith('A'):\n if S[2:-1].count('C') == 1:\n S = S[1] + S[2:-1].replace('C','c') + S[-1]\n if S.islower():\n print('AC')\nelse:\n print('WA')", 'r = int(input())\nprint("ABC" if r < 1200 else "AGC" if r >= 2800 else "ARC")'] | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s108813082', 's161300643', 's468714171', 's645838618'] | [2940.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 18.0, 20.0] | [191, 191, 187, 76] |
p03288 | u853900545 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["S = input()\nS1 = list(S)\n\nif S1[0] == 'A' and S1[2:-1].count('C') == 1 and not(S[1] == 'C' or S[-1] == 'C'):\n print('AC')\nelse:\n print('WA')", "S = input()\nS1 = list(S)\ni = 0\n\nif ((S1[1] == 'C') or (S1[-1] == 'C')):\n print('WA')\nelif ((S1[0] == 'A') and (S1[2:-1].count('C') == 1)):\n S1.remove('A')\n S1.remove('C')\n while i <= len(S1):\n if S1[i].isupper():\n print('WA')\n i += 1\n break\n else:\n print('AC')", "R = int(input())\n\nif R < 1200:\n print('ABC')\nelif R < 2800:\n print('ARC')\nelse:\n print('AGC')"] | ['Wrong Answer', 'Runtime Error', 'Accepted'] | ['s634483433', 's797026884', 's340866715'] | [2940.0, 3064.0, 2940.0] | [18.0, 17.0, 17.0] | [146, 318, 102] |
p03288 | u854093727 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['s = input()\n\nans = "WA"\nif s[0] == "A" and s[2:-1].count("C") == 1 and s[1] != "C" and s[-1] != "C":\n s2 = s.replace("A","a").replace("C","c")\n if s2 == s.lower():\n ans = "AC"\n\nprint(ans)\n', 'S = input()\nresult = "WA"\n\nif S.startswith("A"):\n if S.count("C") == 1 and 2 <= S.find("C") <= (len(S)-3):\n S = S.replace("A","").replace("C","")\n if S.islower():\n result = "AC"\n elif S.count("C") == 1 and S.find("C") == 2:\n S = S.replace("A","").replace("C","")\n if S.islower():\n result = "AC"\nprint(result)\n', 'R = int(input())\n\nif R < 1200:\n print("ABC")\nelif R < 2800:\n print("ARC")\nelse:\n print("AGC")\n'] | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s408694162', 's929218875', 's391182330'] | [2940.0, 2940.0, 2940.0] | [17.0, 18.0, 18.0] | [201, 365, 103] |
p03288 | u859897687 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['a=int(input())\nprint("ABC"if a<1200)\nprint("ARC"if a<2800)\nprint("AGC"if a>2799)', 'a=int(input());print("ABC"if a<1200"ARC"elif a<2800else"AGC")', 'a=int(input())\nif a<1200:\n print("ABC")\nif a<2800:\n print("ARC")\nif a>2799:\n print("AGC")', 'a=int(input())\nprint("ABC")if a<1200\nprint("ARC")if a<2800\nprint("AGC")if a>2799', 'a=int(input())\nif a<1200:\n print("ABC")\nelif a<2800:\n print("ARC")\nelse:\n print("AGC")'] | ['Runtime Error', 'Runtime Error', 'Wrong Answer', 'Runtime Error', 'Accepted'] | ['s438031079', 's568454813', 's599419857', 's609969669', 's023211491'] | [2940.0, 2940.0, 2940.0, 2940.0, 2940.0] | [18.0, 18.0, 17.0, 18.0, 17.0] | [80, 61, 92, 80, 89] |
p03288 | u860546679 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["n=int(input())\nprint('ABC') if n<1200 elif n<2800 print('ARC') else print('AGC')", "n=int(input())\nprint('ABC') if n<1200 else if n<2800 print('ARC') else print('AGC')", "n=int(input())\nprint('ABC') if n<1200 else print('ARC') if n<2800 else print('AGC')"] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s400678073', 's712772236', 's032683169'] | [2940.0, 2940.0, 2940.0] | [17.0, 17.0, 18.0] | [80, 83, 83] |
p03288 | u863370423 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['rating = int(input())\nswitch(rating):\n case rating>0 and rating < 1200:\n print("ABC")\n break\n case rating > 1200 and rating < 2800:\n print("ARC")\n break\n case rating > 2800 :\n print("AGC")\n break\n default:\n print("ERROR")\n break\n', 'rating = int(input())\nif(rating>=0 and rating<1200):\n print("ABC")\nelif(rating < 2800):\n print("ARC")\nelif(rating <= 4208):\n print("AGC")'] | ['Runtime Error', 'Accepted'] | ['s643878682', 's304689784'] | [8948.0, 9164.0] | [23.0, 25.0] | [257, 140] |
p03288 | u864900001 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['s = input()\nl = len(s)\nif s[0] !="A":\n print("WA")\nelse:\n s = s.replace(s[0],"a")\n index1 = s.find("C")\n index2 = s.find("C", 2)\n if index2 != -1 or (index1 < 2 or index1 > l-3):\n print("WA")\n else:\n s = s.replace("A","a")\n s_lower = s.lower()\n if s != s_lower:\n print("WA")\n else:\n print("AC")\n', 's = input()\nl = len(s)\nif s[0] !="A":\n print("WA")\nelse:\n s = s.replace(s[0],"a",1)\n index1 = s.find("C")\n s = s.replace(s[index1],"c",1)\n index2 = s.find("C")\n if index1==-1 or index2 != -1 or (index1 < 2 or index1 > l-3):\n print("WA")\n else:\n s_lower = s.lower()\n if s != s_lower:\n print("WA")\n else:\n print("AC")\n', 'r = int(input())\n\nif r < 1200:\n print("ABC")\nelif r < 2800:\n print("ARC")\nelse:\n print("AGC")'] | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s022836790', 's990001542', 's049397178'] | [3060.0, 3060.0, 2940.0] | [19.0, 17.0, 17.0] | [370, 387, 102] |
p03288 | u867848444 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["import sys\ns=list(input())\nif s[0]!='A':\n break\ncount=0\nfor i in range(2,len(s)-2):\n if s[i]=='C':\n count+=1\n\nif count==1:\n s.remove('A')\n s.remove('C') \n res=''.join(s)\n print('AC' if res.islower()==True else 'WA') \n\nelse:\n print('WA')", "r=int(input())\nif r<1200:\n print('ABC')\nelif 1199<r<2800:\n print('ARC')\nelse:\n print('AGC')"] | ['Runtime Error', 'Accepted'] | ['s632052334', 's125706846'] | [3060.0, 2940.0] | [17.0, 17.0] | [307, 100] |
p03288 | u868263641 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["S = input()\nn = len(S)\ncountc = 0\ncounta = 0\nfor m in range (3, n-1):\n if S[m-1] == 'C':\n countc = countc + 1\n S = S[:m-1] + 'c' + S[m:]\nif S[1-1] == 'A':\n counta = 1\n S = 'a' + S[1:]\nif(countc == 1 and counta == 1 and S.islower()):\n print('AC')\nelse:\n print('WA')", "S = input()\nn = len(S)\ncountc = 0\ncounta = 0\nfor m in range (3, n-1):\n if S[m-1] == 'C':\n countc = countc + 1\n S = S[:m-2] + 'c' + S[m:]\nif S[1-1] == 'A':\n counta = 1\n S = 'a' + S[1:]\nprint(S)\nprint(counta, countc)\nif(countc == 1 and counta == 1 and S.islower()):\n print('AC')\nelse:\n print('WA')", "S = input()\nn = len(S)\ncountc = 0\ncounta = 0\nfor m in range (3, n):\n if S[m-1] == 'C':\n countc = countc + 1\n S = S[:m-2] + 'c' + S[m:]\nif S[1-1] == 'A':\n counta = 1\n S = 'a' + S[1:]\nprint(S)\nprint(counta, countc)\nif(countc == 1 and counta == 1 and S.islower()):\n print('AC')\nelse:\n print('WA')", "S = input()\nn = len(S)\nfor m in range (3, n):\n if S[m-1] == C:\n Count_C = Count_C + 1\n S[m-1].lower()\nif S[1] == A:\n Count_A = 1\n S[1].lower()\nif(Count_C == 1 and Count_A == 1 and S.islower()):\n print('AC')\nelse:\n print('WA')\n\n", "S = input()\nn = len(S)\ncountc = 0\ncounta = 0\nfor m in range (3, n):\n if S[m-1] == 'C':\n countc = countc + 1\n S = S[:m-1] + 'c' + S[m:]\nif S[1-1] == 'A':\n counta = 1\n S = 'a' + S[1:]\nif(countc == 1 and counta == 1 and S.islower()):\n print('AC')\nelse:\n print('WA')", "R = int(input())\nif R < 1200:\n print('ABC')\nelif R < 2800:\n print('ARC')\nelse:\n print('AGC')\n"] | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Wrong Answer', 'Accepted'] | ['s183118684', 's312368178', 's779084344', 's858688858', 's897669548', 's102680098'] | [3064.0, 3064.0, 3064.0, 2940.0, 3064.0, 2940.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [293, 324, 322, 256, 291, 102] |
p03288 | u873262353 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["R = input()\nif R < 1200:\n\tprint('ABC')\nelif R < 2800:\n\tprint('ARC')\nelse:\n\tprint('AGC')\n", "R = int(input())\nif R < 1200:\n\tprint('ABC')\nelif R < 2800:\n\tprint('ARC')\nelse:\n\tprint('AGC')\n\n"] | ['Runtime Error', 'Accepted'] | ['s968262947', 's412115235'] | [2940.0, 2940.0] | [17.0, 17.0] | [88, 94] |
p03288 | u886902015 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['r=input()\nif r<1200:\n print("ABC")\nelif 1200<r<2800:\n print("ARC")\nelse:\n print("AGC")', 'r=int(input())\nif r<1200:\n print("ABC")\nelif 1200<=r<2800:\n print("ARC")\nelse:\n print("AGC")'] | ['Runtime Error', 'Accepted'] | ['s283403627', 's797168687'] | [9016.0, 9032.0] | [20.0, 29.0] | [95, 101] |
p03288 | u893544454 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["\nrating = [('ABC', 1200), ('ARC', 2800), ('AGC', 4209)]\n\n\ntry:\n r = int(input('高橋くんのレーティングを入力してください: '))\n if 0 <= r <= 4208:\n \n for t in rating:\n if r < t[1]:\n print(t[0])\n break\n else:\n print('範囲外の入力値です')\nexcept:\n print('整数値を入力してください')\n", "rating = [('ABC', 1200), ('ARC', 2800), ('AGC', 4209)]\nr = int(input())\nfor t in rating:\n if r < t[1]:\n print(t[0])\n break"] | ['Wrong Answer', 'Accepted'] | ['s995342668', 's594212586'] | [3060.0, 2940.0] | [17.0, 17.0] | [466, 139] |
p03288 | u898967808 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["r = int(input())\nif r >= 2800 :\n print('AGC')\nelif r >= 1200 :\n print('ARC'):\nelse:\n print('ABC')\n ", "r = int(input())\nif r >= 2800 :\n print('AGC')\nelif r >= 1200:\n print('ARC')\nelse:\n print('ABC')"] | ['Runtime Error', 'Accepted'] | ['s018209612', 's220625351'] | [2940.0, 2940.0] | [17.0, 18.0] | [103, 98] |
p03288 | u901865527 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['S = str(input())\nflag = False\n \nif S.startswith("A"):\n if ((S[2]) == "C") ^ (S["-2"]=="C"):\n \tindex = S.find("C")\n for i, s in enumerate(S):\n if (i == 0) or (i == index):\n continue\n if s.islower():\n continue\n if i == len(s):\n flag == True\n \nif flag == True:\n print("AC")\nelse:\n print("WA")', 'S = str(input())\nflag = False\n \nif S.startswith("A"):\n if ((S[2]) == "C") ^ (S[-2]=="C"):\n index = S.find("C")\n if (S[1:index] + S[index+1:]).islower():\n flag = True\n \nif flag == True:\n print("AC")\nelse:\n print("WA")', 'R = int(input())\nif R < 1200:\n print("ABC")\nelif R < 2800:\n print("ARC")\nelse:\n print("AGC")'] | ['Runtime Error', 'Wrong Answer', 'Accepted'] | ['s169394277', 's497661741', 's067319384'] | [2940.0, 3060.0, 2940.0] | [17.0, 18.0, 18.0] | [336, 235, 95] |
p03288 | u903948194 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['D, G = [int(n) for n in input().split()]\n\nscore_table = []\nfor i in range(1, D+1):\n p, c = [int(n) for n in input().split()]\n score_table.append([i*100, p, c])\n\nmin_count = sum([l[1] for l in score_table])\n#print(min_count)\n\nfor bit in range(1<<D):\n score = 0\n count = 0\n\n for i in range(D):\n if bit & (1<<i):\n score += score_table[i][0] * score_table[i][1] + score_table[i][2]\n count += score_table[i][1]\n \n if score >= G:\n min_count = min(min_count, count)\n else:\n additional = []\n for j in range(D):\n if not bit & (1<<j):\n additional.append(score_table[j])\n \n additional_ = sorted(additional, key=lambda x:x[0], reverse=True)\n #print(additional_)\n \n \n # if i[1] > 1:\n # add_score = i\n # break\n\n add_score = additional_[0]\n\n for k in range(add_score[1]-1):\n score += add_score[0]\n count += 1\n if score >= G:\n min_count = min(min_count, count)\n\nprint(min_count)', "R = int(input())\n\nif R < 1200:\n print('ABC')\nelif R < 2800:\n print('ARC')\nelse:\n print('AGC')"] | ['Runtime Error', 'Accepted'] | ['s283698013', 's458985618'] | [9252.0, 2940.0] | [26.0, 17.0] | [1123, 102] |
p03288 | u911612592 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['r = input()\n\nif r < 1200:\n print("ABC")\nelif r < 2800:\n print("ARC")\nelse:\n print("AGC")', 'r = int(input())\n\nif r < 1200:\n print("ABC")\nelif r < 2800:\n print("ARC")\nelse:\n print("AGC")\n'] | ['Runtime Error', 'Accepted'] | ['s358419214', 's139775135'] | [2940.0, 2940.0] | [17.0, 17.0] | [91, 97] |
p03288 | u914198331 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["R = input()\n\nif R < 1200:\n print('ABC')\nelif R < 2800:\n print('ARC')\nelse:\n print('AGC')", "R = int(input())\n\nif R < 1200:\n print('ABC')\nelif R < 2800:\n print('ARC')\nelse:\n print('AGC')"] | ['Runtime Error', 'Accepted'] | ['s959013145', 's850845867'] | [2940.0, 2940.0] | [17.0, 17.0] | [97, 102] |
p03288 | u916787248 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['S = input()\nif S[0] == "A":\n if S[2:-2].count("C") == 1: \n if not S[0:2].upper and S[3:].islower:\n print("AC")\n else:\n print("WA")\n else:\n print("WA")\nelse:\n print("WA")', 'S = input()\nif S[0] == "A":\n if S[2:-2].count("C") == 1:\n if S[1].islower:\n if S[3:].islower:\n print("AC")\n else:\n print("WA")\n else:\n print("WA")\n else:\n print("WA")\nelse:\n print("WA")', 'S = input()\nif S[0] == "A":\n if S[2:-1].count("C") == 1:\n if S[1].islower() and S[3:].islower():\n print("AC")\n else:\n print("WA")\n else:\n print("WA")\nelse:\n print("WA")', 'R = int(input())\nif R >= 2800:\n print("AGC")\nelif R >= 1200:\n print("ARC")\nelse:\n print("ABC")\n'] | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s048770551', 's339923603', 's468453092', 's685027511'] | [2940.0, 3060.0, 2940.0, 2940.0] | [18.0, 17.0, 17.0, 17.0] | [191, 226, 190, 98] |
p03288 | u920299620 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['from math import ceil\nD,G=map(int,input().split())\np=[0]*D\nc=[0]*D\n\nfor i in range(D):\n p[i],c[i]=map(int,input().split())\n_min=101*D\n\nflag=1\nwhile(flag < 2**D):\n \n _G=G\n tmp=0\n max_ind=0\n for i in range(D):\n if(flag & 1<<i):\n _G-=p[i]*(i+1)*100 + c[i]\n tmp+=p[i]\n else:\n max_ind=i\n k=ceil(max([(_G),0])//(100*(max_ind+1))) \n if(k < p[max_ind]):\n tmp+=k\n _min=min([tmp,_min])\n flag+=1\nprint(_min) ', 'from math import ceil\nD,G=map(int,input().split())\np=[0]*D\nc=[0]*D\n\nfor i in range(D):\n p[i],c[i]=map(int,input().split())\n_min=101*D\n\nflag=1\nwhile(flag < 2**D):\n \n _G=G\n tmp=0\n max_ind=0\n for i in range(D):\n if(flag & 1<<i):\n _G-=p[i]*(i+1)*100 + c[i]\n tmp+=p[i]\n else:\n max_ind=i\n k=ceil(max([(_G),0])/(100*(max_ind+1))) \n if(k < p[max_ind]):\n tmp+=k\n _min=min([tmp,_min])\n flag+=1\nprint(_min) ', 'n=int(input())\nif(n<=1199):\n print("ABC")\nelif(n<2800):\n print("ARC")\nelse:\n print("AGC")\n '] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s696998840', 's822696328', 's592141269'] | [3064.0, 3188.0, 2940.0] | [17.0, 18.0, 17.0] | [486, 486, 101] |
p03288 | u921168761 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['解答例\nR = int(input())\n\nif R < 1200:\n\tprint("ABC")\nelif R < 2800:\n\tprint("ARC")\nelse:\n\tprint("AGC")\n', 'R = int(input())\n\nif R < 1200:\n\tprint(“ABC”)\nelif R < 2800:\n\tprint(“ARC”)\nelse:\n\tprint(“AGC”)\n', 'R = int(input())\n\nif R < 1200:\n\tprint("ABC")\nelif R < 2800:\n\tprint("ARC")\nelse:\n\tprint("AGC")\n'] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s387755505', 's592849494', 's262151010'] | [2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0] | [104, 106, 94] |
p03288 | u921830178 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['#110\nS = list(map(int,input().split()))\nans=max(S)-min(S)\nprint(ans)', '#109\nR = int(input())\nif R < 1200:\n print("ABC")\nelif (1200<=R) and (R<2800):\n print("ARC")\nelse:\n print("AGC")'] | ['Wrong Answer', 'Accepted'] | ['s301335684', 's332697009'] | [2940.0, 2940.0] | [17.0, 17.0] | [68, 120] |
p03288 | u924671994 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['n = int(input())\n\nif n<1200:\n print("ABC")\n \nelif 1200=<n<2800:\n print("ARC")\n \nelse:\n print("AGC")', 'n = int(input())\n\nif n<1200:\n print("ABC")\n \nelif 1200<=n<2800:\n print("ARC")\n \nelse:\n print("AGC")'] | ['Runtime Error', 'Accepted'] | ['s502216798', 's278855776'] | [2940.0, 2940.0] | [17.0, 17.0] | [104, 104] |
p03288 | u928784113 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['# -*- coding: utf-8 -*-\nR = int(input())\nif R >=2800:\n print("AGC")\nelif R >= 1200 and 2800 > R:\n print("ARC")\nelse:\n print("AGC")', 'R = int(input())\nif R < 1200:\n ans = "ABC"\nelif R <2800:\n ans = "ARC"\nelse:\n ans = "AGC"\n\nprint(ans)'] | ['Wrong Answer', 'Accepted'] | ['s316596375', 's796211136'] | [2940.0, 2940.0] | [17.0, 17.0] | [133, 109] |
p03288 | u940102677 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['r = input()\nif r < 1200:\n print("ABC")\nelif r < 2800:\n print("ARC")\nelse:\n print("AGC")\n ', 'r = int(input())\nif r < 1200:\n print("ABC")\nelif r < 2800:\n print("ARC")\nelse:\n print("AGC")\n '] | ['Runtime Error', 'Accepted'] | ['s651164457', 's706149056'] | [2940.0, 2940.0] | [17.0, 17.0] | [93, 98] |
p03288 | u941753895 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["print('AGC')", "r=int(input())\nif r<1200:\n\tprint('ABC')\nelif r<2800:\n\tprint('ARC')\nelse:\n\tprint('AGC')"] | ['Wrong Answer', 'Accepted'] | ['s756251423', 's861516222'] | [2940.0, 2940.0] | [17.0, 17.0] | [12, 86] |
p03288 | u955125992 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['def dfs(i, total, S, remain):\n global ans\n if i == D:\n if S < G:\n use = max(remain)\n N = min(L[use-1][0], (G-S)//(100*use))\n S += 100 * N * use\n total += N\n \n if S >= G:\n ans = min(ans, total)\n else:\n dfs(i+1, total, S, remain)\n dfs(i+1, total + L[i][0], S + 100 * (i+1) * L[i][0] + L[i][1], remain - {i+1})\n \nD, G = map(int, input().split())\nL = [list(map(int, input().split())) for _ in range(D)]\nans = 10 ** 9\n \ndfs(0, 0, 0, set(range(1, D+1)))\n \nprint(ans)', "r = int(input())\n\nrate = [1200, 2800, 4209]\ncontest = ['ABC', 'ARC', 'AGC']\n\nfor i in range(3):\n if r < rate[i]:\n break\nprint(contest[i])"] | ['Runtime Error', 'Accepted'] | ['s761392900', 's738131384'] | [3316.0, 2940.0] | [21.0, 17.0] | [557, 147] |
p03288 | u960171798 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['S = list(input())\ncnt = 0\n\narray = S[2:-1]\nif array.count("C")==1:\n array.remove("C")\n S = S[:2]+array+S[-1]\nelse:\n cnt += 1\n\nif S[0]=="A":\n del S[0]\nelse:\n cnt += 1\n\ns = "".join(S)\nif s.islower == False:\n cnt += 1\nprint("AC" if cnt==0 else "WA")\n', 'R = int(input())\nif R < 1200:\n print("ABC")\nelif R < 2800:\n print("ARC")\nelse:\n print("AGC")'] | ['Wrong Answer', 'Accepted'] | ['s560559032', 's062579883'] | [3060.0, 2940.0] | [17.0, 17.0] | [253, 95] |
p03288 | u961674365 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["r=int(input())\nif r<1200:\n print('ABC')\nif 1199<r<2800:\n print('ARC')\nelse:\n print('AGC')", "r=int(input())\nif r<1200:\n print('ABC')\nif 1199<r<2800:\n print('ARC')\nelse:\n print('AGC')\n", "r=int(input())\nif r<1200:\n print('ABC')\nelif 1199<r<2800:\n print('ARC')\nelse:\n print('AGC')\n"] | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s074867358', 's763143496', 's917725897'] | [2940.0, 2940.0, 3060.0] | [18.0, 17.0, 19.0] | [92, 93, 95] |
p03288 | u963880990 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ['n = input()\nif n < 1200:\n print ("ABC")\nelif n < 2800:\n print ("ARC")\nelse:\n print ("AGC")', 'n = int(input())\nif n < 1200:\n print ("ABC")\nelif n < 2800:\n print ("ARC")\nelse:\n print ("AGC")'] | ['Runtime Error', 'Accepted'] | ['s127814653', 's558370615'] | [2940.0, 2940.0] | [18.0, 17.0] | [99, 104] |
p03288 | u977389981 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["S = input()\n\nmid = S[2:-1]\nC_count = 0\n\nfor i in mid:\n if i == 'C':\n C_count += 1\n \nS_lower = S.lower()\nS_replace = S.replace('A', 'a').replace('C', 'c')\n \nif S[0] == 'A' and C_count == 1 and S_lower == S_replace:\n print('AC')\nelse:\n print('WA')", "R = int(input())\nprint('ABC' if R < 1200 else('ARC' if R < 2800 else 'AGC'))"] | ['Wrong Answer', 'Accepted'] | ['s688266306', 's737956322'] | [3060.0, 2940.0] | [17.0, 18.0] | [275, 76] |
p03288 | u977642052 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["'''\nA - Rated for Me\nhttps://atcoder.jp/contests/abc104/tasks/abc104_a\n\n>>> main(1199)\nABC\n>>> main(1200)\nARC\n>>> main(4208)\nAGC\n'''\n\n\ndef main(r):\n if r < 1200:\n print('ABC')\n elif r < 2800:\n print('ARC')\n else:\n print('AGC')\n", '\'\'\'\nA - Rated for Me\nhttps://atcoder.jp/contests/abc104/tasks/abc104_a\n\n>>> main(1199)\nABC\n>>> main(1200)\nARC\n>>> main(4208)\nAGC\n\'\'\'\n\n\ndef main(r):\n if r < 1200:\n print(\'ABC\')\n elif r < 2800:\n print(\'ARC\')\n else:\n print(\'AGC\')\n\n\nif __name__ == "__main__":\n r = int(input())\n main(r)\n'] | ['Wrong Answer', 'Accepted'] | ['s281226675', 's750956332'] | [2940.0, 2940.0] | [17.0, 17.0] | [257, 319] |
p03288 | u980492406 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["a = int(input())\nif a < 1200 :\n prunt('ABC')\nelif a >= 1200 and a < 2800 :\n print('ARC')\nelse :\n print('AGC')", "a = int(input())\nif a < 1200 :\n print('ABC')\nelif a >= 1200 and a < 2800 :\n print('ARC')\nelse :\n print('AGC')"] | ['Runtime Error', 'Accepted'] | ['s796478297', 's078392349'] | [2940.0, 2940.0] | [17.0, 17.0] | [118, 118] |
p03288 | u983918956 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["R=input('レートを入力してください:')\n\nR=int(R)\n\nif 0<=R<1200 :\n print('ABC')\n \nelif 1200<=R<2800 :\n print('ARC')\n\nelif 2800<=R<=4208 :\n print('AGC')", "r=input('レートを入力してください:')\n\nR=int(r)\n\nif 0<=R<1200 :\n print('ABC')\n \nelif 1200<=R<2800 :\n print('ARC')\n\nelif 2800<=R<=4208 :\n print('AGC')", "r=input('レートを入力してください:')\n\nR=int(r)\n\nif 0<=R<1200 :\n print('ABC')\n \nelif 1200<=R<2800 :\n print('ARC')\n\nelif 2800<=R<=4208 :\n print('AGC')\n\nelse :\n print('error')", 'R = int(input())\nif 0<=R<1200:\n print("ABC")\nelif 1200<=R<2800:\n print("ARC")\nelif 2800<=R<=4208:\n print("AGC")'] | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s151536524', 's239223770', 's777169709', 's943535783'] | [2940.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0, 17.0] | [172, 172, 199, 114] |
p03288 | u989157442 | 2,000 | 1,048,576 | A programming competition site _AtCode_ regularly holds programming contests. The next contest on AtCode is called ABC, which is rated for contestants with ratings less than 1200. The contest after the ABC is called ARC, which is rated for contestants with ratings less than 2800. The contest after the ARC is called AGC, which is rated for all contestants. Takahashi's rating on AtCode is R. What is the next contest rated for him? | ["# AcCepted\nimport re\ns = input()\nif s[0] == 'A':\n if s[2:-2:].count('C') == 1:\n if len(re.findall('[ABCDEFGHIJKLMNOPQRSTUVWXYZ]', s)) == 2:\n print('AC')\n exit()\nprint('WA')\n", "# Rated for Me\nr = int(input())\nif r < 1200:\n print('ABC')\nelif r < 2800:\n print('ARC')\nelse:\n print('AGC')\n"] | ['Wrong Answer', 'Accepted'] | ['s783923640', 's259175865'] | [3188.0, 2940.0] | [19.0, 17.0] | [205, 117] |
p03289 | u001024152 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['s = list(input())\n\nflag = True\nif s[0] != "A":\n flag = False\n\nss = s[2:-1]\n# print(ss)\nif ss.count("C") != 1:\n flag = False\nfor si in s:\n if si != "A" or si != "C":\n if si.islower() != True: \n flag = False\nprint("AC" if flag else "WA")\n', 's = list(input())\n\nflag = True\nif s[0] != "A":\n flag = False\n\nss = s[2:-1]\nif ss.count("C") != 1:\n flag = False\nfor si in s:\n if si != "A" and si != "C":\n if si.islower() != True: \n flag = False\n \nprint("AC" if flag else "WA")\n'] | ['Wrong Answer', 'Accepted'] | ['s106951470', 's230574904'] | [3060.0, 3060.0] | [17.0, 17.0] | [263, 265] |
p03289 | u009219947 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["S = input()\n\nif S[0] != 'A':\n print('WA')\n\nif S[3:-1].count('C') != 1:\n print('WA')\n\nif not S.replace('A', '').replace('C', '').islower():\n print('WA')\n \nprint('AC')\n", "S = input()\n\nflag = False\n\nif S[0] == 'A' and S[2:-1].count('C') == 1 :\n if S.count('A') == 1 and S.count('C') == 1:\n if S.replace('A', 'a').replace('C','c').islower():\n flag = True\n\nlog = 'AC' if flag else 'WA'\nprint(log)\n"] | ['Wrong Answer', 'Accepted'] | ['s490863044', 's718097708'] | [2940.0, 3060.0] | [17.0, 18.0] | [170, 232] |
p03289 | u013408661 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['large=list("BDEFGHIJKLMNOPQRSTUVWXYZ")\nsmall=list("abcdefghijklmnopqrstuvwxyz")\ns=list(input())\nif s[0]!="A" or s.count("A")!=1:\n print("WA")\n exit()\nt=s[3:len(s)-1]\nif t.count("C")!=1:\n print("WA")\n exit()\nfor i in s:\n if i in large:\n print("WA")\n exit()\nprint("AC")', 'large=list("BDEFGHIJKLMNOPQRSTUVWXYZ")\nsmall=list("abcdefghijklmnopqrstuvwxyz")\ns=list(input())\nif s[0]!="A" or s.count("A")!=1:\n print("WA")\n exit()\nt=s[2:len(s)-1]\nif t.count("C")!=1:\n print("WA")\n exit()\nfor i in s:\n if i in large:\n print("WA")\n exit()\nprint("AC")'] | ['Wrong Answer', 'Accepted'] | ['s358114540', 's619728679'] | [3064.0, 3064.0] | [17.0, 17.0] | [278, 278] |
p03289 | u015315385 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["import re\n\ns = input()\n\nif not s.startswith('A'):\n print('WA')\nelif s[2:len(s) - 3].count('C') == 1:\n print('WA')\nelif len(re.findall('[A-Z]', s)) != 2:\n print('WC')\nelse:\n print('AC')\n", "s = input()\n\nif not s.startswith('A'):\n print('WA')\nelif s[2:len(s) - 3].count('C') == 1:\n print('WA')\nelse:\n print('AC')", "import re\n\ns = input()\n\nif not s.startswith('A'):\n print('WA')\nelif s[2:len(s) - 1].count('C') != 1:\n print('WA')\nelif len(re.findall('[A-Z]', s)) != 2:\n print('WA')\nelse:\n print('AC')\n"] | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s499614573', 's933117603', 's839517283'] | [3188.0, 2940.0, 3188.0] | [19.0, 19.0, 19.0] | [197, 130, 197] |
p03289 | u015593272 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["S = input()\n\ncap = S[0]\nmid = list(S[2:-1])\nprint(mid)\n\nif (mid.count('C') >= 1):\n index = S.index('C')\n strr = S[1:index] + S[index + 1 :]\nelse:\n print('WA')\n exit()\n\n\nif (cap == 'A' and mid.count('C') == 1 and strr.islower() == True):\n print('AC')\nelse:\n print('WA')\n", "S = input()\n\ncap = S[0]\nmid = list(S[2:-1])\n\nif (mid.count('C') >= 1):\n index = S.index('C')\n strr = S[1:index] + S[index + 1 :]\nelse:\n print('WA')\n exit()\n\n\nif (cap == 'A' and mid.count('C') == 1 and strr.islower() == True):\n print('AC')\nelse:\n print('WA')\n\n"] | ['Wrong Answer', 'Accepted'] | ['s060845240', 's498438645'] | [3060.0, 3060.0] | [17.0, 19.0] | [287, 277] |
p03289 | u016302627 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["import sys\nS = input()\nif S[0] != 'A':\n print('WA')\n sys.exit()\n \nn = len(S)\nct = 0\nfor i in range(1, n):\n if S[i].islower():\n if i == 1 or i == n - 1 or S[i] != 'C':\n print('WA')\n sys.exit()\n ct += 1\nif ct == 1:\n print('AC')\nelse:\n print('WA')", "import sys\nS = input()\nif S[0] != 'A' or :\n print('WA')\n sys.exit()\n \nn = len(S)\nct = 0\nfor i in range(1, n):\n if S[i].islower():\n if i == 1 or i == n - 1 or S[i] != 'C':\n print('WA')\n sys.exit()\n ct += 1\nif ct == 1:\n print('AC')\nelse:\n print('WA')", "import sys\nS = input()\nif S[0] != 'A':\n print('WA')\n sys.exit()\n \nn = len(S)\nct = 0\nfor i in range(1, n):\n if S[i].islower() == False:\n if i == 1 or i == n - 1 or S[i] != 'C':\n print('WA')\n sys.exit()\n ct += 1\nif ct == 1:\n print('AC')\nelse:\n print('WA')"] | ['Wrong Answer', 'Runtime Error', 'Accepted'] | ['s228867083', 's449984297', 's859206064'] | [3064.0, 2940.0, 3064.0] | [17.0, 18.0, 19.0] | [298, 302, 307] |
p03289 | u023229441 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['S=input()\nn=len(S)\nif S[0]=="A":\n\tif 2<=S.find("C")<=n-2:\n\t\tT=S.lstrip("A")\n\t\tR=T.replace("C","c",1)\n\t\tQ=T.replace("C","c")\n\t\tif R==Q:\n\t\t\tif R.lower()==R:\n\t\t\t\tprint("AC")\nprint("WA")\n\t\t\t', 'S=input()\nn=len(S)\nif S[0]=="A":\n\tif 2<=S.find("C")<=n-2:\n\t\tT=S.lstrip("A")\n\t\tR=T.replace("C","c",1)\n\t\tQ=T.replace("C","c")\n\t\tif R==Q:\n\t\t\tif R.lower()==R:\n\t\t\t\tprint("AC")\n\t\t\t\texit()\nprint("WA")\n\t\t\t'] | ['Wrong Answer', 'Accepted'] | ['s659382634', 's357303696'] | [3060.0, 2940.0] | [18.0, 18.0] | [186, 197] |
p03289 | u030726788 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['A=list(input())\nn=len(A)\nif(A[0]!="A"):print("WA")\nelif(A.count("C")!=1):print("WA")\nelif(A.index("C")<2 or A.index("C")>n-2):print("WA")\nelse:\n A.pop(A.index("C"))\n A.pop(0)\n if(A.islower()):print("AC")\n else:print("WA")', "\ns = input()\n\n\ns1 = s[0]\n\n\ns2 = s[2:-1]\n\n\ns = s.replace('A','')\ns = s.replace('C','')\n\n\n\nt = s.lower()\n\nif(s1 == 'A' and s2.count('C') == 1 and t == s): \n print('AC')\nelse:\n print('WA')\n"] | ['Runtime Error', 'Accepted'] | ['s088761837', 's726455373'] | [3064.0, 3060.0] | [17.0, 19.0] | [225, 596] |
p03289 | u033606236 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['s = input()\nprint("AC" if s[0] == "A" and s[2:len(s)-1].count("C") == 1 and s.replace("C","",1).islower() else "WA")', 's = input()\nprint("AC" if s[0] == "A" and s[2:len(s)-1].count("C") == 1 and s[1:].replace("C","",1).islower() else "WA")'] | ['Wrong Answer', 'Accepted'] | ['s913907149', 's283586757'] | [2940.0, 2940.0] | [17.0, 17.0] | [116, 120] |
p03289 | u035445296 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['s = input()\nans = \'No\'\nif s[0] == \'A\' and \'C\' in s[2:len(s)-1]:\n s = s.replace(\'A\', \'\').replace(\'C\', \'\')\n if all([i in [chr(i) for i in range(97, 97+26)] for i in s]):\n ans = "Yes"\nprint(ans)', "s = input()\nans = 'WA'\nif s[0] == 'A' and s[2:len(s)-1].count('C') == 1:\n s = s.replace('A', '').replace('C', '')\n if all([i in [chr(i) for i in range(97, 97+26)] for i in s]):\n ans = 'AC'\nprint(ans)"] | ['Wrong Answer', 'Accepted'] | ['s647817624', 's328552903'] | [9036.0, 9004.0] | [28.0, 27.0] | [196, 204] |
p03289 | u036340997 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["s = input()\n\nif s[0] == 'A' and s[2:-1].count('C') == 1:\n for letter in s[1:]:\n if letter != letter.lower():\n print('WA')\n break\n else:\n print('AC')\nelse:\n print('AC')", "s = input()\n\nif s[0] == 'A' and s[2:-1].count('C') == 1:\n for letter in s[1:]:\n if letter != letter.lower() or letter == 'C':\n print('WA')\n break\n else:\n print('AC')\nelse:\n print('AC')\n", "s = input()\n\nif s[0] == 'A' and s[2:-1].count('C') == 1:\n for letter in s[1:]:\n if letter != letter.lower() or letter != 'C':\n print('WA')\n break\n else:\n print('AC')\nelse:\n print('AC')\n", "s = input()\n\nif s[0] == 'A' and s[2:-1].count('C') == 1:\n for letter in s[1:]:\n if letter != letter.lower() and letter != 'C':\n print('WA')\n break\n else:\n print('AC')\nelse:\n print('WA')\n"] | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s575550994', 's624862722', 's692468306', 's619809392'] | [3060.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 18.0, 17.0] | [186, 204, 204, 205] |
p03289 | u037221289 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["S = input()\nlead = S[0]\nsub = S[2:-1]\nC = sub.count('C')\nif lead == 'A' and C == 1:\n for x,i in enumerate(1,len(S)):\n if i =='C' and ( 2<= x < len(S)-2):\n pass\n else:\n if i.islower():\n pass\n else:\n print('WA')\n exit()\n print('AC')\n exit()\nelse:\n print('WA')", "import re\nx = input()\nC_index = 0\ndef calc1():\n return x[0] == 'A'\n\ndef calc2():\n if len(re.findall('C', x[2:-2])) == 1:\n C_index = int(x.find('C'))\n return True\n\n\ndef calc3():\n for i in range(0,len(x)):\n if x[i] == x[0] or x[i] == x[C_index]:\n continue\n elif x[i].isupper():\n return False\n break\n else:\n continue\n return True\n \n\nif calc1() and calc2() and calc3():\n print('AC')\nelse:\n print('WA')", "S = input()\nlead = S[0]\nsub = S[2:-1]\nC = sub.count('C')\nif lead == 'A' and C == 1:\n for x in range(1,len(S)):\n if S[x].islower() or S[x] == 'C':\n pass\n else:\n print('WA')\n exit()\n print('AC')\nelse:\n print('WA')"] | ['Runtime Error', 'Wrong Answer', 'Accepted'] | ['s559104736', 's620869867', 's644906545'] | [3060.0, 3188.0, 3060.0] | [17.0, 20.0, 17.0] | [303, 504, 235] |
p03289 | u038408819 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["S = input()\n\n#c_index = S.index('C')\nif S[0] != 'A':\n print('WA')\n quit()\nelif S.count('C') != 1:\n print('WA')\n quit()\nc_index = S.index('C')\nelif 2 > c_index or c_index > len(S) - 2:\n print('WA')\n quit()\nelse:\n disc = S[1:c_index] + S[c_index + 1:]\nalpha = 'abcdefghijklmnopqrstuvwxyz'\nfor i in range(len(disc)):\n if not disc[i] in alpha:\n print('WA')\n quit()\n else:\n continue\nprint('AC')", "S = input()\n\nC_S = S[2 : len(S) - 1]\n\n\nif S[0] != 'A':\n \n print('WA')\n quit()\n #break\nif not 'C' in C_S and C_S.count('C') != 1:\n \n #break\n print('WA')\n quit()\nc_index = S.index('C')\nalpha = 'abcdefghijklmnopqrstuvwxyz'\nfor i in range(len(S)):\n if i == 0 or i == c_index:\n continue\n elif S[i] not in alpha:\n \n #break\n print('WA')\n quit()\n else:\n continue\nprint('AC')"] | ['Runtime Error', 'Accepted'] | ['s509682275', 's307015700'] | [2940.0, 3064.0] | [17.0, 18.0] | [437, 492] |
p03289 | u044459372 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["def solve(s):\n if s[0]!='A':\n return 'WA'\n if s[3:len(s)-1].count('C')!=1:\n return 'WA'\n s=s.split('A').split('C')\n if not s.islower():\n return 'WA'\n return 'AC'\n \ns=input()\nprint(solve(s))\n \t\n", "def solve(s):\n\tif s[0]!='A':\n \treturn 'WA'\n if s[3:len(s)-1].count('C')!=1:\n \treturn 'WA'\n s=s.split('A').split('C')\n if not s.islower():\n \treturn 'WA'\n return 'AC'\n \ns=input()\nprint(solve())\n \t", "def solve(s):\n if s[0]!='A':\n return 'WA'\n if s[3:len(s)-1].count('C')!=1:\n return 'WA'\n s=s.split('A').split('C')\n if not s.islower():\n return 'WA'\n return 'AC'\n \ns=input()\nprint(solve(s))\n \t\n", "def solve(s):\n if s[0]!='A':\n return 'WA'\n if s[3:len(s)-1].count('C')!=1:\n return'WA'\n s=s.split('A').split('C')\n if not s.islower():\n return'WA'\n return'AC'\n \ns=input()\nprint(solve(s))\n \t\n", "def solve(s):\n if s[0]!='A':\n return 'WA'\n if s[3:len(s)-2].count('C')!=1:\n return 'WA'\n s=str(s.split('A'))\n s=str(s.split('C'))\n if not s.islower():\n return 'WA'\n return 'AC'\n \ns=input()\nprint(solve(s))\n \t\n", "def solve(s):\n if s[0]!='A':\n return 'WA'\n if s[3:len(s)-2].count('C')!=1:\n return 'WA'\n s=str(s.split('A'))\n s=str(s.split('C'))\n if not s.islower():\n return 'WA'\n return 'AC'\n \ns=input()\nprint(solve(s))\n \t\n", "def solve(s):\n if s[0]!='A':\n return 'WA'\n if s[2:len(s)-1].count('C')!=1:\n return 'WA'\n s=str(s.split('A'))\n s=str(s.split('C'))\n if not s.islower():\n return 'WA'\n return 'AC'\n\ns=input()\nprint(solve(s))"] | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s209258776', 's254964758', 's640191115', 's655891614', 's793476068', 's970996658', 's322962044'] | [2940.0, 2940.0, 2940.0, 2940.0, 3060.0, 3060.0, 3060.0] | [17.0, 17.0, 17.0, 18.0, 17.0, 19.0, 17.0] | [233, 219, 233, 230, 251, 251, 242] |
p03289 | u044952145 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['if S[0] == "A" and S[2:-1].count("C") == 1:\n i = S.index("C")\n S = S[1:i] + S[i+1:]\n if S.islower():\n print("AC")\n else:\n print("WA")\nelse:\n print("WA")', 'S = input()\naccept = False\n\nif S[0] == "A" and S[2:-1].count("C") == 1:\n i = S.index("C")\n S = S[1:i] + S[i+1:]\n if S.islower():\n accept = True\n\nif accept:\n print("AC")\n\nelse:\n print("WA")'] | ['Runtime Error', 'Accepted'] | ['s836279690', 's724042428'] | [2940.0, 3060.0] | [24.0, 17.0] | [186, 211] |
p03289 | u060569392 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['S="AcycliC"\n\nlow_count=0\n\nfor s in S:\n if s.islower()==True:\n low_count+=1\n \n \n\nif low_count ==len(S)-2:\n if S[0] == "A":\n count=0\n \n for i in S[2:-1]:\n if i in "C":\n count+=1\n \n if count !=0:\n print(\'AC\')\n else:\n print(\'WC\')\n else:\n print(\'WC\')\n \nelse:\n print(\'WC\')', 'S=input()\n\nlow_count=0\n\nfor s in S:\n if s.islower()==True:\n low_count+=1\n \n else:\n print(\'WC\')\n \n \n\nif low_count ==len(S)-2:\n if S[0] == "A":\n count=0\n \n for i in S[2:-1]:\n if i in "C":\n count+=1\n \n if count !=0:\n print(\'AC\')\n else:\n print(\'WC\')\n else:\n print(\'WC\')\n \nelse:\n print(\'WC\')', 's=input()\n\ndef check(s):\n if not s[0] == \'A\':\n return False\n if not s[2:-1].count(\'C\') == 1:\n return False\n \n count=0\n \n for i in s[1:]:\n if not i.lower() == i:\n count+=1\n if count>1:\n return False\n \n return True\nprint("AC" if check(s) else "WA")'] | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s833604254', 's889749907', 's996065408'] | [3068.0, 3060.0, 3064.0] | [18.0, 17.0, 17.0] | [393, 426, 332] |
p03289 | u061406236 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['s = input()\n\nif s[0] != \'A\':\n print(\'WA\')\n exit()\n\nif s[2:-1].count(\'C\') != 1:\n print(\'WA\')\n exit()\n\ns = s.replace(\'C\',"")\n\nif s[1:].isLower():\n print(\'AC\')\nelse:\n print(\'WA\')', 's = input()\n\nif s[0] != \'A\':\n print(\'WA\')\n exit()\n\nif s[2:-1].count(\'C\') != 1:\n print(\'WA\')\n exit()\n\ns = s.replace(\'C\',"")\n\nif s[1:].islower():\n print(\'AC\')\nelse:\n print(\'WA\')'] | ['Runtime Error', 'Accepted'] | ['s238128728', 's136494542'] | [9020.0, 8972.0] | [26.0, 27.0] | [217, 217] |
p03289 | u063073794 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["yandy\nS = input()\n\nif S[0] == 'A' and S[2:-1].count('C') == 1:\n c = S.index('C')\n if S[1:c].islower() and S[c+1:].islower():\n print('AC')\n exit()\n\n\nprint('WA')\n", 's = input()\n\nif s[0]=="A" and s[2:-1].count("C")==1 and s[1:].replace("C","a",1).islower()==True:\n print(\'AC\')\nelse:\n print(\'WA\')'] | ['Runtime Error', 'Accepted'] | ['s906887977', 's089343857'] | [2940.0, 2940.0] | [17.0, 17.0] | [180, 131] |
p03289 | u066455063 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['S = list(input())\n\nac = False\nif S[0] == "A":\n if S[2:len(S)-1].count("C") == 1:\n ac = True\n\nupper = False\ncount = 0\nfor i in S:\n if i.isupper():\n count += 1\n\nif count == 1:\n upper = True\n\nif ac and upper:\n print("AC")\nelse:\n print("WA")\n', 'S = list(input())\n\nac = False\nif S[0] == "A":\n if S[2:len(S)-1].count("C") == 1:\n ac = True\n\n upper = False\n count = 0\nfor i in S[2:len(S)-1]:\n if i.isupper():\n count += 1\n\nif count == 1:\n upper = True\n\nif ac and upper:\n print("AC")\nelse:\n print("WA")\n', 'S = list(input())\n\nac = False\nif S[0] == "A":\n if S[2:len(S)-1].count("C") == 1:\n ac = True\n\nupper = False\ncount = 0\nfor i in S:\n if i.isupper():\n count += 1\n\nif count == 2:\n upper = True\n\nif ac and upper:\n print("AC")\nelse:\n print("WA")\n'] | ['Wrong Answer', 'Runtime Error', 'Accepted'] | ['s189908834', 's599496124', 's114477960'] | [3060.0, 2940.0, 3060.0] | [18.0, 17.0, 17.0] | [267, 281, 267] |
p03289 | u068142202 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['import string\n\ns = list(input())\nflag = True\nif s[0] != "A":\n flag = False\ns.pop(0)\nif s.count("C") > 1:\n flag = False\ns_index = s.index("C")\nif 2 >= s_index or s_index <= (len(s) - 3):\n flag = False\ns.pop(s_index)\nfor i in s:\n if i not in string.ascii_lowercase:\n flag = False\n\nif flag:\n print("AC")\nelse:\n print("WA")\n', 'import string\n\ns = list(input())\nflag = True\nif s[0] != "A":\n flag = False\ncount = 0\nfor i in range(1, len(s)):\n if s[i] in string.ascii_uppercase:\n if i == 1 or i == len(s) - 1 or s[i] != "C":\n flag = False\n count += 1\n\nif flag and count == 1:\n print("AC")\nelse:\n print("WA")\n'] | ['Runtime Error', 'Accepted'] | ['s270270927', 's854531821'] | [9796.0, 9920.0] | [40.0, 39.0] | [345, 314] |
p03289 | u069533671 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['def checker():\n s = input()\n if s[0] != "A":\n return 0\n if "C" not in s[2:-1]:\n return 0\n return 1\n\nl = ["AC", "WA"]\n\nprint(l[checker()])', 'def checker():\n s = input()\n if s[0] != "A":\n return 0\n if s[2:-1].count("C") != 1:\n return 0\n s.pop(0)\n s.pop(s.index("C"))\n if s != s.lower():\n return 0\n return 1\n\nl = ["WA", "AC"]\n\nprint(l[checker()])', 'def checker():\n s = input()\n if s[0] != "A":\n return 0\n if "C" in s[2:-1]:\n s[2:-1].pop(s[2:-1].index("C"))\n if "C" in s[2:-1]:\n return 0\n else:\n return 1\n return 1\n\nl = ["WA", "AC"]\n\nprint(l[checker()])', 'def checker():\n s = input()\n if s[0] != "A":\n return 0\n if s[2:-1].count("C") != 1:\n return 0\n num = s.index("C")\n s = s[1:num] + s[num+1:]\n if s != s.lower():\n return 0\n return 1\n\nl = ["WA", "AC"]\n\nprint(l[checker()])\n'] | ['Wrong Answer', 'Runtime Error', 'Runtime Error', 'Accepted'] | ['s772056990', 's919881618', 's938432063', 's801112649'] | [2940.0, 3064.0, 3060.0, 2940.0] | [19.0, 17.0, 18.0, 17.0] | [163, 245, 265, 261] |
p03289 | u074445770 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['S=input()\nif S[0]=="A" and S[2:-1].count("C")==1:\n\tindex=s.index("C")\n\tS=S[1:index]+S[index+1:]\n\tif S.islower():\n\t\tprint("AC")\n\telse:\n\t\tprint("WA")\t\nelse:\n\tprint("WA")\t\t', 'S=input()\nif S[0]=="A" and S[2:-1].count("C")==1:\n\tindex=S.index("C")\n\tS=S[1:index]+S[index+1:]\n\tif S.islower():\n\t\tprint("AC")\n\telse:\n\t\tprint("WA")\t\nelse:\n\tprint("WA")\t\t'] | ['Runtime Error', 'Accepted'] | ['s136001577', 's307054876'] | [3060.0, 3188.0] | [19.0, 20.0] | [169, 169] |
p03289 | u077019541 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['S = [i for i in input()]\nprint(S[2:-2])\nif S[0]=="A" and S[2:-1].count("C")==1:\n S.remove("A")\n S.remove("C")\n if "".join(S).islower():\n print("AC")\n else:\n print("WA")\nelse: \n print("WA")', 'S = [i for i in input()]\nif S[0]=="A":\n if S[3:-2].count("C")==1:\n S.remove("A")\n S.remove("C")\n if "".join(S).islower():\n print("AC")\n else:\n print("WA")\n print("WA")\nprint("WA")', 'S = [i for i in input()]\nif S[0]=="A" and S[3:-2].count("C")==1 :\n S.remove("A")\n S.remove("C")\n if "".join(S).islower():\n print("AC")\n else:\n print("WA")\nelse: \n print("WA")', 'S = [i for i in input()]\nif S[0]=="A" and S[2:-1].count("C")==1:\n S.remove("A")\n S.remove("C")\n if "".join(S).islower():\n print("AC")\n else:\n print("WA")\nelse: \n print("WA")'] | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s048654281', 's230287414', 's891677840', 's672548827'] | [3060.0, 3060.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0, 18.0] | [221, 235, 208, 206] |
p03289 | u077075933 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['s = input()\nprint("AC" if(s[0] == "A" and s[2:len(s)-1].count("C") == 1 and (s[1:s.find(\'C\')]+s[s.find(\'C\')+1:]).islower())\n', 's = input()\nprint("AC" if(s[0] == "A" and s[2:len(s)-1].count("C") == 1 and (s[1:s.find(\'C\')]+s[s.find(\'C\')+1:]).islower()) else "WA")\n'] | ['Runtime Error', 'Accepted'] | ['s330216935', 's489919937'] | [2940.0, 2940.0] | [17.0, 18.0] | [124, 135] |
p03289 | u077291787 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['# ABC104B - AcCepted\ns = input().rstrip()\nif (\n s[0] == "A"\n and s[2:-1].count("C") == 1\n and s.translate(str.maketrans({"A": None, "C": None}).islower()\n):\n print("AC")\nelse:\n print("WA")', '# ABC104B - AcCepted\ndef main():\n S = input().rstrip()\n flags = [S[0] == "A", S[2:-1].count("C") == 1, S.translate(str.maketrans({"A": None, "C": None})).islower()]\n print("AC" if all(flags) else "WA")\n\n\nif __name__ == "__main__":\n main()\n'] | ['Runtime Error', 'Accepted'] | ['s899720537', 's360513357'] | [2940.0, 2940.0] | [17.0, 17.0] | [203, 251] |
p03289 | u078349616 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['S = input()\nif S[0] != "A":\n print("WA")\n exit()\nelif S[2:-2].count("C") != 1:\n print("WA")\n exit()\nelse:\n if S.count("C") != 0:\n print("WA")\n else:\n S = S[1:].replace("C", "")\n if S.islower():\n print("AC")\n else:\n print("WA")', 'S = input()\nif S[0] != "A":\n print("WA")\n exit()\nelif S[2:-2].count("C") == 1 and S.count("C") == 1:\n print("WA")\n exit()\nelse:\n S = S[1:].replace("C", "")\n if S.islower():\n print("AC")\n else:\n print("WA")', 'S = input()\nif S[0] != "A":\n print("WA")\n exit()\nelif S[2:-1].count("C") != 1 or S[:2].count("C") != 0 or S[-1:].count("C") != 0:\n print("WA")\n exit()\nelse:\n S = S[1:].replace("C", "")\n if S.islower():\n print("AC")\n else:\n print("WA")'] | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s454617992', 's745364252', 's689278084'] | [3060.0, 3060.0, 3060.0] | [17.0, 17.0, 18.0] | [254, 218, 247] |
p03289 | u089032001 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['S = input()\n\ncA = S[0:1] == "A"\ncC = False\nif(S[2:-1].find("C") != -1 and S[2:-1].count("C") == 1):\n S = S[1:] + S[2:-1].strip("C") + S[-1:]\n cC = S.islower()\nif(cA and cC):\n print("AC")\nelse:\n print("WA")', 'S = input()\n\ncA = S[0:1] == "A"\ncC = False\nif(S[2:-1].count("C") == 1):\n A = S[1:2] + S[2:-1].replace("C", "") + S[-1:]\n # print(S)\n cC = A.islower()\nif(cA and cC):\n print("AC")\nelse:\n print("WA")'] | ['Wrong Answer', 'Accepted'] | ['s229144718', 's275475826'] | [3060.0, 3060.0] | [17.0, 19.0] | [217, 211] |
p03289 | u089142196 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['S=input()\nflag=False\n\nif S[0]=="A":\n if S[2:-1].count("C")==1:\n pos=S.find("C")\n T=S[1:pos]+S[pos+1:]\n if T.islower():\n print("AC")\n flag=True\n \nif flag=False:\n print("WA")', 'S=input()\nflag=False\n\nif S[0]=="A":\n if S[2:-1].count("C")==1:\n pos=S.find("C")\n T=S[1:pos]+S[pos+1:]\n if T.islower():\n print("AC")\n flag=True\n \nif flag==False:\n print("WA")'] | ['Runtime Error', 'Accepted'] | ['s609629882', 's981733153'] | [2940.0, 3060.0] | [17.0, 17.0] | [198, 199] |
p03289 | u090001078 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['letters = input()\nC = letters[2:-2]\nD = letters.replace("A","a").replace("C","c")\n\nprint(D)\nif letters[0] == "A" and C.count("C") == 1 and D.islower() == True :\n print("AC")\nelse:\n print("WA")', 'letters = input()\nC = letters[2:-1]\nD = letters.replace("A","a").replace("C","c")\n\nif letters[0] == "A" and C.count("C") == 1 and D.islower() == True :\n print("AC")\nelse:\n print("WA")'] | ['Wrong Answer', 'Accepted'] | ['s757747166', 's100273125'] | [3060.0, 2940.0] | [17.0, 17.0] | [195, 186] |
p03289 | u090406054 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["import copy\ns=list(input())\nif s[0]=='A' and 'C' in s[2:len(s)] :\n t=copy.copy(s)\n s.remove('A')\n s.remove('C')\n result=''.join(s)\n if len(s)==len(t)-2 and result.islower()==True and t[s-1]!='C':\n print('AC')\n else:\n print('WA')\n \nelse:\n print('WA')\n", "import copy\ns=list(input())\nif s[0]=='A' and 'C' in s[2:len(s)] :\n t=copy.copy(s)\n s.remove('A')\n s.remove('C')\n result=''.join(s)\n if len(s)==len(t)-2 and result.islower()==True and t[len(s-1)]!='C':\n print('AC')\n else:\n print('WA')\n \nelse:\n print('WA')\n", "import copy\ns=list(input())\nif s[0]=='A' and 'C' in s[2:len(s)] :\n t=copy.copy(s)\n s.remove('A')\n s.remove('C')\n result=''.join(s)\n if len(s)==len(t)-2 and result.islower==True:\n print('AC')\n else:\n print('WA')\n \nelse:\n print('WA')", "import copy\ns=list(input())\nif s[0]=='A' and 'C' in s[2:len(s)] :\n t=copy.copy(s)\n s.remove('A')\n s.remove('C')\n result=''.join(s)\n if len(s)==len(t)-2 and result.islower()==True and t[-1]!='C':\n print('AC')\n else:\n print('WA')\n \nelse:\n print('WA')\n"] | ['Runtime Error', 'Runtime Error', 'Wrong Answer', 'Accepted'] | ['s112631168', 's576152719', 's657234003', 's055766284'] | [3444.0, 3444.0, 3444.0, 3444.0] | [24.0, 23.0, 22.0, 23.0] | [266, 271, 247, 265] |
p03289 | u094191970 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["S=list(input())\nif S[0]=='A' and S[2:len(S)].count('C')==1:\n S[2:len(S)].remove('C')\n del S[0]\n if str(S).islower():\n print('AC')\n else:\n print('WA')\nelse:\n print('WA')", "s=input()\nif s[0]=='A' and s[2:-1].count('C')==1:\n for i in range(len(s[2:-1])):\n if s[2:-1][i]=='C':\n ind=i+2\n ss=s[1:ind]+s[ind+1:]\n if ss==ss.lower():\n print('AC')\n exit()\nprint('WA')"] | ['Wrong Answer', 'Accepted'] | ['s830286524', 's857221868'] | [3060.0, 3060.0] | [17.0, 17.0] | [197, 227] |
p03289 | u102902647 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["S = input()\nflag = True\nif S[0] == 'A':\n pass\nelse:\n flag = False\n\ncnt = 0\nfor i in range(len(S)-3):\n if S[3+i] =='C':\n cnt += 1\nif cnt == 1:\n pass\nelse:\n flag=False\n\ncnt = 0\nfor i in range(len(S)):\n if S[i].islower():\n cnt += 1\nif cnt == 2:\n pass\nelse:\n flag=False\n\nif flag:\n print('AC')\nelse:\n print('WA')", "S = input()\nflag = True\nif S[0] == 'A':\n pass\nelse:\n flag = False\n\ncnt = 0\nfor i in range(len(S)-3):\n if S[2+i] =='C':\n cnt += 1\n\nif cnt == 1:\n pass\nelse:\n flag=False\ncnt = 0\nfor i in range(len(S)):\n if S[i].islower():\n cnt += 1\nif cnt == len(S)-2:\n pass\nelse:\n flag=False\nif flag:\n print('AC')\nelse:\n print('WA')"] | ['Wrong Answer', 'Accepted'] | ['s681881634', 's336682815'] | [3064.0, 3064.0] | [17.0, 17.0] | [351, 357] |
p03289 | u102960641 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['s = input()\nif s[0] == "A" and s[2:-1].count("C") == 1:\n index_C = s.find("C")\n print(index_C)\n if s[1:index_C].islower() and s[index_C+1:].islower():\n print("AC")\n else:\n print("WA")\nelse:\n print("WA")', 's = input()\nif s[0] == "A" and s[2:-1].count("C") == 1:\n index_C = s.find("C")\n print(index_C)\n if s[1:index_C].islower() and s[index_C+1:]:\n print("AC")\n else:\n print("WA")\nelse:\n print("WA")', 's = input()\nif s[0] == "A" and s[2:-1].count("C") == 1:\n s[s[2:-1].find("C")] = c\n if s[1:].islower():\n print("AC")\n else:\n print("WA")\nelse:\n print("WA")', 's = input()\nif s[0] == "A" and s[2:-1].count("C") == 1:\n index_C = s.find("C")\n if s[1:index_C].islower() and s[index_C+1:].islower():\n print("AC")\n else:\n print("WA")\nelse:\n print("WA")'] | ['Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Accepted'] | ['s330826116', 's426187804', 's844061271', 's401526665'] | [3060.0, 3060.0, 2940.0, 3060.0] | [18.0, 18.0, 19.0, 18.0] | [213, 203, 164, 196] |
p03289 | u103902792 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["s = input()\nif s[0]!='A' or s[2:-1].count('C')!= 1:\n print('WA')\n exit()\n \nfor c in s[1:]:\n if not('a'<= c <= 'z') or c=='C':\n print('WA')\n break\nelse:\n print('AC')", "s = input()\nif s[0]!='A' or s[2:-1].count('C')!= 1:\n print('WA')\n exit()\n \nfor c in s[1:]:\n if not(('a'<= c <= 'z') or c=='C'):\n print('WA')\n break\nelse:\n print('AC')\n\n"] | ['Wrong Answer', 'Accepted'] | ['s116681687', 's102394108'] | [3060.0, 2940.0] | [18.0, 17.0] | [175, 180] |
p03289 | u105124953 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["import sys\ndef check_small(string):\n if string in 'abcdefghijklmnopqrstuvwxyz':\n return True\n else:\n return False\n\ns = input()\nif s[0] != 'A':\n print('WA')\n sys.exit()\nif check_small(s[-1]) == False:\n print('WA')\n sys.exit()\ncount = 0\nfor si in s[3:]:\n if si == 'C':\n count += 1\n elif check_small(si) == False:\n print('WA')\n sys.exit()\nprint('AC' if count == 1 else 'WA')", "import sys\ndef check_small(string):\n if string in 'abcdefghijklmnopqrstuvwxyz':\n return True\n else:\n return False\n\ns = input()\nif s[0] != 'A':\n print('WA')\n sys.exit()\nif check_small(s[-1]) == False:\n print('WA')\n sys.exit()\ncount = 0\nfor si in s[3:]:\n if si == 'C':\n count += 1\nprint('AC' if count == 1 else 'WA')\n\n\n", "import sys\ndef check_small(string):\n if string in 'abcdefghijklmnopqrstuvwxyz':\n return True\n else:\n return False\n\ns = input()\nif s[0] != 'A':\n print('WA')\n sys.exit()\nif check_small(s[-1]) == False or check_small(s[1]) == False:\n print('WA')\n sys.exit()\ncount = 0\nfor si in s[2:]:\n if si == 'C':\n count += 1\n elif check_small(si) == False:\n print('WA')\n sys.exit()\nprint('AC' if count == 1 else 'WA')"] | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s777675059', 's964728075', 's464981557'] | [3064.0, 3060.0, 3188.0] | [17.0, 17.0, 19.0] | [450, 367, 480] |
p03289 | u105456682 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['import random as r;print(r.choice(["AC","WA"]))', 'import re;print("AC"if re.match("A[a-z]+C[a-z]+$",input())else"WA")'] | ['Wrong Answer', 'Accepted'] | ['s133426655', 's560975534'] | [3316.0, 3188.0] | [22.0, 19.0] | [47, 67] |
p03289 | u111421568 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['s = input()\n\nf = 1\nc = 0\n\nfor i in range(len(s)):\n on = 0\n if i==0:\n if not s[i]==\'A\':\n f = 0\n on = 1\n elif i>=2 and i<=len(s)-2:\n if s[i] == \'C\':\n c += 1\n on = 1\n \n if on == 0 and s[i].islower()==False:\n f = 0\n \nif c!=1:\n f=0\n \nif f==0:\n print("WA")\nelse:\n print("AC")', 's = input()\n\nf = 1\nc = 0\n\nfor i in range(len(s)):\n on = 0\n if i==0:\n if not s[i]==\'A\':\n f = 0\n else:\n on = 1\n elif i>=2 and i<=len(s)-2:\n if s[i] == \'C\':\n c += 1\n on = 1\n \n if on == 0 and s[i].islower()==False:\n f = 0\n \nif c!=1:\n f=0\n \nif f==0:\n print("WA")\nelse:\n print("AC")'] | ['Wrong Answer', 'Accepted'] | ['s347141778', 's165840841'] | [3064.0, 3064.0] | [17.0, 17.0] | [376, 390] |
p03289 | u113003638 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["s = input()\nprint('AC' if s[1] == 'A' and 'C' in s[3:-1] and s[1:].replace('C','',1).islower() else 'WA')", "s = input()\nprint('AC' if s[1] == 'A' and 'C' in s[2:-1] and s[1:].replace('C','',1).islower() else 'WA')", "s = input()\nprint('AC' if s[0] == 'A' and 'C' in s[2:-1] and s[1:].replace('C','',1).islower() else 'WA')"] | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s613370708', 's659673014', 's162454355'] | [3064.0, 2940.0, 2940.0] | [17.0, 18.0, 17.0] | [105, 105, 105] |
p03289 | u113255362 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['S = input()\nflag = True\ncount = 0\nif not S[0] == "A":\n flag = False\nfor i in range(2,len(S)-1):\n if S[i] == "C":\n count += 1\n else:\n if not S[len(S)].islower():\n flag = False \nif not S[len(S)].islower():\n flag = False\nif not count == 1:\n flag = False\nif flag:\n print("AC")\nelse:\n print("WA")', 'S = input()\nflag = True\ncount = 0\nif not S[0] == "A":\n flag = False\nfor i in range(2,len(S)-1):\n if S[i] == "C":\n count += 1\n else:\n if not S[i].islower():\n flag = False\nif not S[1].islower():\n flag = False\nif not S[len(S)-1].islower():\n flag = False\nif not count == 1:\n flag = False\nif flag:\n print("AC")\nelse:\n print("WA")'] | ['Runtime Error', 'Accepted'] | ['s151620063', 's814679531'] | [9028.0, 9044.0] | [24.0, 26.0] | [309, 343] |
p03289 | u113971909 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["S=input()\nC1=S[0]=='A' and S[-1].islower()\nC1=C1 and S[1].islower()\nC2=0\nC3=0\nfor i in S[2:len(S)-1]:\n if i=='C':\n C2+=1\n elif i.islower():\n else:\n C3+=1\nif C1 and C2==1 and C3==0:\n print('AC')\nelse:\n print('WA')\n", "S=input()\nC1=(S[0]=='A')\nC2=0\nfor i in range(2:len(S)):\n if S[i]=='C' and i in range(2:len(S)-1):\n C2+=1\n else:\n C1=C1 and S[i].islower()\nif C1 and C2==1:\n print('AC')\nelse:\n print('WA')", "S=input()\nC1=S[0]=='A' and S[-1].islower()\nC1=C1 and S[1].islower()\nC2=0\nC3=0\nfor i in S[2:len(S)-1]:\n if i=='C':\n C2+=1\n elif i.islower():\n C3=C3\n else:\n C3+=1\nif C1 and C2==1 and C3==0:\n print('AC')\nelse:\n print('WA')\n"] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s037185492', 's813997303', 's643359049'] | [2940.0, 2940.0, 3060.0] | [17.0, 17.0, 18.0] | [224, 196, 234] |
p03289 | u119714109 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['import sys\n\nstdin = sys.stdin\n\nni = lambda: int(ns())\nna = lambda: list(map(int, stdin.readline().split()))\nns = lambda: stdin.readline()\n\ns = ns()\nok = False\nif s.startswith("A"):\n if s[2:-1].count("C") == 1:\n ct = 0\n for c in s:\n if "a" <= c <= "z":\n ct += 1\n if ct == len(s)-2:\n ok = True\nprint("AC" if ok else "WA")\n', 'import sys\n\nstdin = sys.stdin\n\nni = lambda: int(ns())\nna = lambda: list(map(int, stdin.readline().split()))\nns = lambda: stdin.readline()\n\ns = ns().rstrip()\nok = False\nif s.startswith("A"):\n if s[2:-1].count("C") == 1:\n ct = 0\n for c in s:\n if "a" <= c <= "z":\n ct += 1\n if ct == len(s)-2:\n ok = True\nprint("AC" if ok else "WA")\n'] | ['Wrong Answer', 'Accepted'] | ['s163023877', 's232026552'] | [3060.0, 3064.0] | [17.0, 17.0] | [381, 390] |
p03289 | u122195031 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['s = list(input())\n\nif s[0] == "A" and s[2:-1].count("C") == 1:\n s.remove("C")\n s.pop(0)\n print(s)\n s_ = "".join(s)\n if s_.islower() == True:\n print("AC")\n exit()\nprint("WA")', 's = list(input())\n \nif s[0] == "A" and s[2:-1].count("C") == 1:\n s.remove("C")\n s.pop(0)\n s_ = "".join(s)\n if s_.islower() == True:\n print("AC")\n exit()\nprint("WA")'] | ['Wrong Answer', 'Accepted'] | ['s032110575', 's436070134'] | [3060.0, 3060.0] | [20.0, 17.0] | [202, 190] |
p03289 | u123745130 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['i=input()\nif i[0]=="A"and i[2:-1].count("C")==1:\n i[2:-1].replace("C","c",1)\n if i[1:].islower()==True:\n print("AC")\nelse:print("WA")', 'i=input()\nif i[0]=="A"and i[2:-1].count("C")==1\\\nand i[1:].replace("C","c",1).islower()==True:\n print("AC")\nelse:print("WA")'] | ['Wrong Answer', 'Accepted'] | ['s111812284', 's339634906'] | [3060.0, 2940.0] | [21.0, 17.0] | [146, 127] |
p03289 | u125666426 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["S = input()\n\na = S[0] == 'A'\nb = S[2:-2].count('C') == 1\nif a and b:\n S = list(S)\n print(S)\n print(S[-1])\n S_1 = S[2:-2]\n S_1.remove('C')\n S = S[0:2] + S_1 + S[-2:]\n del S[0]\n print(S)\n c = str(S).islower()\n\nif a and b and c:\n print('AC')\nelse:\n print('WA')\n", "S = input()\n\na = S[0] == 'A'\nb = S[2:-1].count('C') == 1\nif a and b:\n S = list(S)\n S_1 = S[2:-1]\n S_1.remove('C')\n# print(S[0:2])\n# print(S_1)\n# print(S[-1:])\n S = S[0:2] + S_1 + S[-1:]\n del S[0]\n# print(S)\n c = str(S).islower()\n\nif a and b and c:\n print('AC')\nelse:\n print('WA')\n"] | ['Wrong Answer', 'Accepted'] | ['s239816975', 's545917854'] | [3064.0, 3060.0] | [18.0, 17.0] | [291, 316] |
p03289 | u127499732 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['s=str(input())\nf=s[0]=="A" and s[2:-1].count("C")==1\ng=(s[:2]+s[2:-1].replace("A","a").replace("C","c")+s[-1]).islower()\nh=f and g\nprint("AC" if h is True else "WA")', 's=str(input())\nf=s[0]=="A" and s[2:-1].count("C")==1\ng=(s[1]+s[2:-1].replace("A","a").replace("C","c")+s[-1]).islower()\nh=f and g\nprint("AC" if h is True else "WA")'] | ['Wrong Answer', 'Accepted'] | ['s888813370', 's055732155'] | [3060.0, 3060.0] | [17.0, 17.0] | [165, 164] |
p03289 | u128914900 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['s=input()\nresult=""\ncount=0\nl=len(s)\nif s[0]!="A":\n result="WA"\nelif ord(s[1:2])<97 or ord(s[l-1])<97:\n result="WA"\nfor i in s[2:l-1]:\n if ord(i)<97:\n count+=1\n if count>1:\n result="WA"\n break\nif count==0:\n result="WA"\nprint(result)\n', 's=input()\nresult=""\ncount=0\nl=len(s)\nfor i in range(l):\n if i==0 and s[i]="A":\n result="WA"\n break\n elif i==1 and ord(s[1])<97 \n result="WA"\n break\n elif i==l-1 and ord(s[l-1])<97:\n result="WA"\n break\n else:\n if ord(i)<97:\n count+=1\n if count>1:\n result="WA"\n break\nif result!="WA"\n result="AC"\nprint(result)\n', 's=input()\nresult=""\ncount=0\nl=len(s)\nif s[0]!="A":\n result="WA"\nelif ord(s[1:2])<97 or ord(s[l-1])<97:\n result="WA"\nfor i in s[2:l-1]:\n if ord(i)<97:\n count+=1\n if ord(i)<97 and i!="C":\n result="WA"\n break\n if count>1:\n result="WA"\n break\nif count==0:\n result="WA"\nif result!="WA":\n result="AC"\nprint(result)'] | ['Wrong Answer', 'Runtime Error', 'Accepted'] | ['s894099349', 's973595352', 's692377470'] | [3060.0, 2940.0, 3064.0] | [17.0, 18.0, 18.0] | [247, 353, 330] |
p03289 | u131406572 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['n=input()\nwa=0\n#print(n[2:len(n)-1])\nif n[0]=="A" and n[2:len(n)-1].count("C")==1 and n[1]!="C" and n[len(n)]!="C":\n wa+=0\n import re\n a=re.sub(\'[AC ]\', \'\',n)\nelse:\n wa+=1\n a=n\nfor i in range(len(a)):\n if 0<= ord(a[i]) - ord(\'a\') <= 26:\n wa+=0\n else:\n wa+=1\nif wa==0:\n print("AC")\nelse:\n print("WA")', 'n=input()\nwa=0\n#print(n[2:len(n)-1])\n#print(n[len(n)])\nif n[0]=="A" and n[2:len(n)-1].count("C")==1 and n[1]!="C" and n[len(n)-1]!="C":\n wa+=0\n import re\n a=re.sub(\'[AC ]\', \'\',n)\nelse:\n wa+=1\n a=n\nfor i in range(len(a)):\n if 0<= ord(a[i]) - ord(\'a\') <= 26:\n wa+=0\n else:\n wa+=1\nif wa==0:\n print("AC")\nelse:\n print("WA")'] | ['Runtime Error', 'Accepted'] | ['s304005355', 's784503747'] | [3064.0, 3188.0] | [17.0, 20.0] | [340, 360] |
p03289 | u133347536 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['s = list(input())\nflag = True\nif s[0] != "A":\n flag = False\nc = False\nif s[1].islower():\n flag = False\nfor i in range(len(s) - 3):\n if s[i + 2] == "C":\n if c:\n flag = False\n c = True\n else:\n if s[i + 2].islower():\n flag = False\n\nif s[-1].islower():\n flag = False\n\n\nif flag and c:\n print("AC")\nelse:\n print("WA")\n', 's = list(input())\nflag = True\nif s[0] != "A":\n flag = False\nc = False\nif s[1].isupper() and s[1] != "A" and s[1] != "C":\n flag = False\nfor i in range(len(s) - 3):\n if s[i + 2] == "C":\n if c:\n flag = False\n c = True\n else:\n if s[i + 2].isupper() and s[i + 2] != "A" and s[i + 2] != "C":\n flag = False\n\nif s[-1].isupper() and s[-1] != "A" and s[-1] != "C":\n flag = False\n\n\nif flag and c:\n print("AC")\nelse:\n print("WA")\n'] | ['Wrong Answer', 'Accepted'] | ['s309842905', 's864639293'] | [3060.0, 3064.0] | [17.0, 17.0] | [376, 482] |
p03289 | u137228327 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["# coding: utf-8\n# Your code here!\nimport sys\ns = str(input())\n\nch = s[0]\n\ntest_st = s[2:-1]\n#print(test_st)\ncount = 0\nif ch == 'A':\n for i in range(len(test_st)):\n if test_st[i] == 'C':\n count += 1\n if count == 1:\n test_stx = test_st[:i]+test_st[i+1:]\n if count == 1 and test_stx.islower():\n print(test_stx,test_st)\n print('AC')\n else:\n print('WA')\nelse:\n print('WA')\n \n", "import sys\ns = str(input())\n\nif s[0] != 'A':\n print('WA')\n sys.exit()\n \ntest_st = s[2:-1]\n#print(test_st)\ntest_stx =''\nfor i in range(len(test_st)):\n if test_st[i] == 'C':\n test_stx = s[1]+test_st[:i] + test_st[i+1:]+s[-1]\n #print(test_stx)\n \nif test_stx.islower() and len(test_stx) >0:\n print('AC')\nelse:\n print('WA')\n "] | ['Wrong Answer', 'Accepted'] | ['s993562357', 's321219661'] | [8720.0, 8744.0] | [29.0, 23.0] | [454, 358] |
p03289 | u141968173 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["import re\nprint('YES') if re.match(r'A[a-z]+C[a-z]+', input()) else print('NO')", "import re\nprint('AC') if re.match(r'^A[a-z]+C[a-z]+$', input()) else print('WA')"] | ['Wrong Answer', 'Accepted'] | ['s331576775', 's495154022'] | [3188.0, 3188.0] | [19.0, 22.0] | [79, 80] |
p03289 | u152638361 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['S = list(input())\nans ="AC"\nif S[0]!="A":\n ans ="WA"\nif S.count("C") !=1:\n ans ="WA"\nif S[2:-1].count("C")!=1:\n ans ="WA"\nif S[0]==("A"):\n del S[0]\nif S.count("C")>0:\n S.remove("C")\nfor i in range(len(S)):\n if (S[i]).isupper:\n ans = "WA"\nprint(ans)', 'S = list(input())\nans ="AC"\nif S[0]!="A":\n ans ="WA"\nif S.count("C") !=1:\n ans ="WA"\nif S[2:-1].count("C")!=1:\n ans ="WA"\nif S[0]==("A"):\n del S[0]\nif S.count("C")>0:\n S.remove("C")\nS = str(S)\nfor i in range(len(S)):\n if (S[i]).isupper():\n ans = "WA"\nprint(ans)'] | ['Wrong Answer', 'Accepted'] | ['s499390130', 's982778881'] | [3064.0, 3064.0] | [17.0, 17.0] | [273, 286] |
p03289 | u156383602 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ['s=input()\nif s[0]!="A":\n print("WA")\nelif "C" not in s[2:] or s[2:].count("C")!=1:\n print("WA")\nelif s[1:].strip("C")==str.lower(s[1:].strip("C")):\n print("AC")\n \nelse:\n print("WA")', '#104\ns=input()\nif s[0]!="A":\n print("WA")\nelif "C" not in s[2:-1] or s[2:-1].count("C")!=1:\n print("WA")\nelif s[1]==str.upper(s[1]):\n print("WA")\nelif (s[1:2]+s[-1]).strip("C")==str.lower((s[1:2]+s[-1]).strip("C")):\n print("AC")\nelse:\n print("WA")'] | ['Wrong Answer', 'Accepted'] | ['s098500724', 's071924063'] | [3060.0, 3064.0] | [19.0, 17.0] | [196, 262] |
p03289 | u159335277 | 2,000 | 1,048,576 | You are given a string S. Each character of S is uppercase or lowercase English letter. Determine if S satisfies all of the following conditions: * The initial character of S is an uppercase `A`. * There is exactly one occurrence of `C` between the third character from the beginning and the second to last character (inclusive). * All letters except the `A` and `C` mentioned above are lowercase. | ["s = input()\n\na = -1\nc = -1\nlower = 0\nfor i in range(len(s))\n if s[i] == 'A':\n a = i\n if s[i] == 'C':\n c = i\n if 'a' <= s[i] <= 'z':\n lower += 1\n\nif a == 0 and 2 <= c <= len(s) - 2 and lower == len(s) - 2:\n print('AC')\nelse:\n print('WA')", "s = input()\n\na = -1\nc = -1\nlower = 0\nfor i in range(len(s)):\n if s[i] == 'A':\n a = i\n if s[i] == 'C':\n c = i\n if 'a' <= s[i] <= 'z':\n lower += 1\n\nif a == 0 and 2 <= c <= len(s) - 2 and lower == len(s) - 2:\n print('AC')\nelse:\n print('WA')\n"] | ['Runtime Error', 'Accepted'] | ['s941458544', 's795993365'] | [8992.0, 9056.0] | [27.0, 29.0] | [250, 252] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.