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 |
|---|---|---|---|---|---|---|---|---|---|---|
p03072 | u870062840 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['import sys\n\n\ndef CheckRangeInt(input_str,_min,_max):\n\n if input_str.isdecimal()==0 or int(input_str)<_min or int(input_str)>_max:\n print("error")\n sys.exit()\n\n return int(input_str)\n\n\ndef CheckRangeList(input_list,_min,_max):\n for i in range(len(input_list)) :\n if H[i]<_min... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s939581236', 's939581236', 's939581236', 's939581236', 's733807876', 's733807876', 's733807876', 's733807876'] | [3064.0, 3064.0, 3064.0, 3064.0, 3064.0, 3064.0, 3064.0, 3064.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [665, 665, 665, 665, 2319, 2319, 2319, 2319] |
p03072 | u875028418 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['n=int(input())\nnumlist=list(map(int,input().split()))\ncount=1\nfor i in range(n):\n for j in range(i):\n if numlist[i]<numlist[j]:\n break\n else:\n count+=1\nprint(count)', 'n=int(input())\nnumlist=list(map(int,input().split()))\ncount=1\nfor i in range(n):\n for j in range(i):\n if numlist[i]<num... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s289269338', 's289269338', 's289269338', 's289269338', 's961248679', 's961248679', 's961248679', 's961248679'] | [3060.0, 3060.0, 3060.0, 3060.0, 2940.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [177, 177, 177, 177, 177, 177, 177, 177] |
p03072 | u878481059 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['n = int(input())\nhs = map(int, input().split())\ncount = 1\nmaxh = 0\nfor i in range(1,n):\n\tmaxh = max(maxh, hs[i-1])\n\tif hs[i]>maxh:\n\t\tcount += 1\nprint(count)', 'n = int(input())\nhs = map(int, input().split())\ncount = 1\nmaxh = 0\nfor i in range(1,n):\n\tmaxh = max(maxh, hs[i-1])\n\tif hs[i]>maxh:\n\t\tco... | ['Runtime Error', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', ... | ['s327015806', 's327015806', 's418536917', 's418536917', 's423786636', 's423786636', 's512873801', 's512873801', 's755329927', 's755329927', 's327015806', 's327015806', 's418536917', 's418536917', 's423786636', 's423786636', 's512873801', 's512873801', 's755329927', 's755329927', 's697920422', 's697920422', 's697920422... | [3060.0, 3060.0, 3060.0, 3060.0, 2940.0, 2940.0, 2940.0, 2940.0, 3060.0, 3060.0, 3060.0, 3060.0, 3060.0, 3060.0, 2940.0, 2940.0, 2940.0, 2940.0, 3060.0, 3060.0, 2940.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 18.0, 18.0, 18.0, 18.0] | [156, 156, 168, 168, 169, 169, 159, 159, 154, 154, 156, 156, 168, 168, 169, 169, 159, 159, 154, 154, 169, 169, 169, 169] |
p03072 | u885523920 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['n=int(input())\nlist=[int(input()) for x in range(n)]\na=0\ndef max(list,k):\n t=max(list[:k])\n return t\nfor j in range(n):\n if max(list,j)<=list[j]:\n a=a+1\n else:\n pass\nprint(a)', 'n=int(input())\nlist=[int(input()) for x in range(n)]\na=0\ndef max(list,k):\n t=max(list[:k])\n return t\nfor j in r... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Erro... | ['s055708282', 's055708282', 's223412196', 's223412196', 's288427345', 's288427345', 's354901903', 's354901903', 's759812608', 's759812608', 's776565595', 's776565595', 's055708282', 's055708282', 's223412196', 's223412196', 's288427345', 's288427345', 's354901903', 's354901903', 's759812608', 's759812608', 's776565595... | [2940.0, 2940.0, 2940.0, 2940.0, 3060.0, 3060.0, 2940.0, 2940.0, 3060.0, 3060.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 3060.0, 3060.0, 2940.0, 2940.0, 3060.0, 3060.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 20.0, 20.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 20.0, 20.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [184, 184, 141, 141, 180, 180, 161, 161, 140, 140, 156, 156, 184, 184, 141, 141, 180, 180, 161, 161, 140, 140, 156, 156, 145, 145, 145, 145] |
p03072 | u895810656 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ["cnt = 1\nN = int(input())\nH = list(map(int, input().split(' ')))\nfor i in range(1,N-1,1):\n _cnt=0\n for j in range(0,i,1):\n if H[i]>=H[j]:\n _cnt+=1\n if _cnt==i:\n cnt+=1\nprint(cnt)", "cnt = 1\nN = int(input())\nH = list(map(int, input().split(' ')))\nfor i in range(1,N-1,1):\n _cnt=0\n for j in... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s283458017', 's283458017', 's283458017', 's283458017', 's437422952', 's437422952', 's437422952', 's437422952'] | [3060.0, 3060.0, 3060.0, 3060.0, 3060.0, 3060.0, 3060.0, 3060.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [191, 191, 191, 191, 189, 189, 189, 189] |
p03072 | u896741788 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['p,a=1,0\nn=input()\nfor i in list(map(int,input().split())):\n if p<=i:ans+=1\n p=i\nprint(ans)', 'p,a=1,0\nn=input()\nfor i in list(map(int,input().split())):\n if p<=i:ans+=1\n p=i\nprint(ans)', 'p,a=1,0\nn=input()\nfor i in list(map(int,input().split())):\n if p<=i:ans+=1\n p=i\nprint(a)', 'p,a=1,0\nn=input(... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s267344044', 's267344044', 's717113553', 's717113553', 's267344044', 's267344044', 's717113553', 's717113553', 's473540510', 's473540510', 's473540510', 's473540510'] | [2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0] | [18.0, 18.0, 17.0, 17.0, 18.0, 18.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [92, 92, 90, 90, 92, 92, 90, 90, 96, 96, 96, 96] |
p03072 | u897302879 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['N = int(input())\nHs = list(map(int, input().split()))\nprint(len([i for i in range(0, len(Hs)) if all(lambda j: Hs[j]<=Hs[j+1]), range(0, i)]))', 'N = int(input())\nHs = list(map(int, input().split()))\nprint(len([i for i in range(0, len(Hs)) if all(lambda j: Hs[j]<=Hs[j+1]), range(0, i)]))', 'N = int(input())\nHs =... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s708711063', 's708711063', 's708711063', 's708711063', 's418453817', 's418453817', 's418453817', 's418453817'] | [2940.0, 2940.0, 2940.0, 2940.0, 3060.0, 3060.0, 3060.0, 3060.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [142, 142, 142, 142, 142, 142, 142, 142] |
p03072 | u899421906 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['N = int(input())\nH = input().split()\nx = []\nfor i in H:\n x.append(int(i))\nans = 1\nfor i in range(N - 1):\n if x[i] <= x[i + 1]:\n ans = ans + 1\n else:\n break\nprint(ans)', 'N = int(input())\nH = input().split()\nx = []\nfor i in H:\n x.append(int(i))\nans = 1\nfor i in range(N - 1):\... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s208104015', 's208104015', 's208104015', 's208104015', 's556706795', 's556706795', 's556706795', 's556706795'] | [2940.0, 2940.0, 2940.0, 2940.0, 3064.0, 3064.0, 3064.0, 3064.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [189, 189, 189, 189, 242, 242, 242, 242] |
p03072 | u903722008 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['n=input()\na=list(map(int,input().split()))\nh = a[0]\ncount = 0\nfor i in len(a):\n if h <= a[i]:\n count =+ 1\nprint(count)', 'n=input()\na=list(map(int,input().split()))\nh = a[0]\ncount = 0\nfor i in len(a):\n if h <= a[i]:\n count =+ 1\nprint(count)', 'n=input()\na=list(map(int,input().split(... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s495557718', 's495557718', 's495557718', 's495557718', 's680563246', 's680563246', 's680563246', 's680563246'] | [2940.0, 2940.0, 2940.0, 2940.0, 3060.0, 3060.0, 3060.0, 3060.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [128, 128, 128, 128, 159, 159, 159, 159] |
p03072 | u905715926 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['now = 0\nans = 0\nn = int(input())\nli = list(map(int,input().split()))\nfor i in li:\n if now >= i:\n now = i\n ans += 1\nprint(ans)', 'now = 0\nans = 0\nn = int(input())\nli = list(map(int,input().split()))\nfor i in li:\n if now >= i:\n now = i\n ans += 1\nprint(ans)', 'now = 0\na... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s289923302', 's289923302', 's289923302', 's289923302', 's495682972', 's495682972', 's495682972', 's495682972'] | [2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [142, 142, 142, 142, 143, 143, 143, 143] |
p03072 | u906093973 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['n = int(input())\nh = list(map(int, input().split()))\n\ncount = 0\n\nfor num, hight in enumerate(h):\n if h[num] >= max(h[:num]):\n count += 1\n\nprint(count)', 'n = int(input())\nh = list(map(int, input().split()))\n\ncount = 0\n\nfor num, hight in enumerate(h):\n if h[num] >= max(h[:num]):\n count += 1\n\n... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s341909537', 's341909537', 's341909537', 's341909537', 's153841078', 's153841078', 's153841078', 's153841078'] | [2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [154, 154, 154, 154, 155, 155, 155, 155] |
p03072 | u908349502 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['count = 0\n\nn = int(input())\nh = list(map(int, input().split()))\n\nfor i in range(n):\n h_short = h[:i+1] \n print(h_short)\n if h[i] >= max(h_short):\n count += 1\n \nprint(count)\n\n', 'count = 0\n\nn = int(input())\nh = list(map(int, input().split()))\n\nfor i in range(n):\n h_short = h[:i+1] \n print(... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s844236230', 's844236230', 's844236230', 's844236230', 's258079475', 's258079475', 's258079475', 's258079475'] | [2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [181, 181, 181, 181, 162, 162, 162, 162] |
p03072 | u914330401 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['N = int(input())\nlist = input().split()\n \nM = 0\nis_cand = True\nfor i in range(0, N): \n is_cand = True\n for j in range(0, i): \n if list[i] < list[j]: \n is_cand = False\n break\n if is_cand:\n M += 1\nprint(M)', 'N = int(input())\nlist = input().split()\n \nM = 0\nis_cand = True\nfor i i... | ['Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'R... | ['s026656337', 's026656337', 's049770081', 's049770081', 's262367931', 's262367931', 's663429194', 's663429194', 's926169597', 's926169597', 's958872242', 's958872242', 's026656337', 's026656337', 's049770081', 's049770081', 's262367931', 's262367931', 's663429194', 's663429194', 's926169597', 's926169597', 's958872242... | [2940.0, 2940.0, 3060.0, 3060.0, 2940.0, 2940.0, 3060.0, 3060.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 3060.0, 3060.0, 2940.0, 2940.0, 3060.0, 3060.0, 2940.0, 2940.0, 2940.0, 2940.0, 3060.0, 3060.0, 3060.0, 3060.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 18.0, 18.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 18.0, 18.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [317, 317, 223, 223, 221, 221, 157, 157, 206, 206, 196, 196, 317, 317, 223, 223, 221, 221, 157, 157, 206, 206, 196, 196, 166, 166, 166, 166] |
p03072 | u914642030 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ["import math\nimport os\nimport random\nimport re\nimport sys\nfrom collections import defaultdict\n\nsys.stdin = open('input.in', 'r')\nsys.stdout = open('output.out', 'w') \n\ndef count(n, h):\n\tcount = 0\n\tif len(h) < 1:\n\t\treturn count\n\tmax = h[0]\n\tfor i in h:\n\t\tif i >= max:\n\t\t\tmax = i \n\t\t\tcount... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s564739941', 's564739941', 's941459531', 's941459531', 's564739941', 's564739941', 's941459531', 's941459531', 's628097626', 's628097626', 's628097626', 's628097626'] | [3956.0, 3956.0, 2940.0, 2940.0, 3956.0, 3956.0, 2940.0, 2940.0, 4460.0, 4460.0, 4460.0, 4460.0] | [27.0, 27.0, 18.0, 18.0, 27.0, 27.0, 18.0, 18.0, 36.0, 36.0, 36.0, 36.0] | [418, 418, 351, 351, 418, 418, 351, 351, 422, 422, 422, 422] |
p03072 | u917013605 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['N = input()\nmt_lst = list(map(int, input().split()))\ncnt = 0\n\nfor i in range(len(mt_lst)):\n tmp = mt_lst[0:i+1]\n cnt += 1 if mt_lst[i] == max(tmp) else 0\n', 'N = input()\nmt_lst = list(map(int, input().split()))\ncnt = 0\n\nfor i in range(len(mt_lst)):\n tmp = mt_lst[0:i+1]\n cnt += 1 if mt_lst[i] ... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s127538404', 's127538404', 's127538404', 's127538404', 's855002900', 's855002900', 's855002900', 's855002900'] | [2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [160, 160, 160, 160, 172, 172, 172, 172] |
p03072 | u918845030 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['n = int(input())\nh = list(map(int, input().split()))\n\nprint(h)\nmax = 0\n\ncount = 0\nfor i in range(len(h)):\n if h[i] >= max:\n count +=1\n max = h[i]\n\nprint(count, "\\n")\n\n', 'n = int(input())\nh = list(map(int, input().split()))\n\nprint(h)\nmax = 0\n\ncount = 0\nfor i in range(len(h)):\n ... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s220279244', 's220279244', 's237580866', 's237580866', 's591469895', 's591469895', 's778495373', 's778495373', 's220279244', 's220279244', 's237580866', 's237580866', 's591469895', 's591469895', 's778495373', 's778495373', 's896466438', 's896466438', 's896466438', 's896466438'] | [3060.0, 3060.0, 3060.0, 3060.0, 3060.0, 3060.0, 2940.0, 2940.0, 3060.0, 3060.0, 3060.0, 3060.0, 3060.0, 3060.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [184, 184, 187, 187, 177, 177, 177, 177, 184, 184, 187, 187, 177, 177, 177, 177, 166, 166, 166, 166] |
p03072 | u923341003 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['N = int(input())\nH = list(map(int,input().split()))\n\nc = 0\n\nfor i in range(N):\n d = 0\n\n for j in range(i):\n #print(H[i], H[j])\n if H[i] > H[j] or H[i] == H[j]:\n d += 1\n if d == i:\n c += 1\nc', 'N = int(input())\nH = list(map(int,input().split()))\n\nc = 0\n\nfor i... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s829357879', 's829357879', 's829357879', 's829357879', 's960255229', 's960255229', 's960255229', 's960255229'] | [2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [230, 230, 230, 230, 237, 237, 237, 237] |
p03072 | u924594299 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['n = int(input())\nH = [int(i) for i in input().strip().split()]\n \nborder = 0\ncan_num = 0\nfor h in H:\n if h > border:\n can_num += 1\n border = h\n \nprint(can_num)', 'n = int(input())\nH = [int(i) for i in input().strip().split()]\n \nborder = 0\ncan_num = 0\nfor h in H:\n if h > border:\n can_num += ... | ['Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s702640543', 's702640543', 's717764114', 's717764114', 's702640543', 's702640543', 's717764114', 's717764114', 's822466653', 's822466653', 's822466653', 's822466653'] | [2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [165, 165, 145, 145, 165, 165, 145, 145, 166, 166, 166, 166] |
p03072 | u932868243 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['n=int(input())\nlisth=(list(map(int,input().split()))\ncount=0\nfor i in range(2,n+1):\n if listh[i-1]>=max(listh[:i-1]):\n count+=1\nprint(count+1)\n', 'n=int(input())\nlisth=(list(map(int,input().split()))\ncount=0\nfor i in range(2,n+1):\n if listh[i-1]>=max(listh[:i-1]):\n count+=1\nprint(count+1)\n', 'n=... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s020094747', 's020094747', 's255324633', 's255324633', 's408397524', 's408397524', 's497835982', 's497835982', 's020094747', 's020094747', 's255324633', 's255324633', 's408397524', 's408397524', 's497835982', 's497835982', 's619080857', 's619080857', 's619080857', 's619080857'] | [2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 3064.0, 3064.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 3064.0, 3064.0, 3060.0, 3060.0, 3060.0, 3060.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [147, 147, 148, 148, 154, 154, 145, 145, 147, 147, 148, 148, 154, 154, 145, 145, 119, 119, 119, 119] |
p03072 | u934868410 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['n = int(input())\nh = list(map(int, input().split()))\nmax_h = 0\nans = 0\nfor a in h:\n if max <= a:\n ans += 1\n max_h = max(a, max_h)\n \nprint(ans)', 'n = int(input())\nh = list(map(int, input().split()))\nmax_h = 0\nans = 0\nfor a in h:\n if max <= a:\n ans += 1\n max_h = max(a, max_h)\n \nprint(ans)... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s548094752', 's548094752', 's548094752', 's548094752', 's022561110', 's022561110', 's022561110', 's022561110'] | [3064.0, 3064.0, 3064.0, 3064.0, 2940.0, 2940.0, 2940.0, 2940.0] | [18.0, 18.0, 18.0, 18.0, 17.0, 17.0, 17.0, 17.0] | [148, 148, 148, 148, 150, 150, 150, 150] |
p03072 | u939585142 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['N = int(input())\nH = [map(int,input().split())]\nprint(H)', 'N = int(input())\nH = [map(int,input().split())]\nprint(H)', 'N = int(input())\nH = [map(int,input().split())]\nprint(H)', 'N = int(input())\nH = [map(int,input().split())]\nprint(H)', 'N = int(input())\nH = []\nfor i in map(int,input().split()):\n H.appe... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s525213172', 's525213172', 's525213172', 's525213172', 's299130705', 's299130705', 's299130705', 's299130705'] | [2940.0, 2940.0, 2940.0, 2940.0, 3060.0, 3060.0, 3060.0, 3060.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [56, 56, 56, 56, 147, 147, 147, 147] |
p03072 | u945761460 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['n=int(input())\na=int(input())\ncnt=1\nfor i in range(n-1):\n b=int(input())\n if a<=b:\n cnt++\n a=b\n\nprint(cnt)', 'n=int(input())\na=int(input())\ncnt=1\nfor i in range(n-1):\n b=int(input())\n if a<=b:\n cnt++\n a=b\n\nprint(cnt)', 'n=int(input())\na=int(input())\ncnt=1\nfor i in range(n-1):\n b... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s247303792', 's247303792', 's247303792', 's247303792', 's111390896', 's111390896', 's111390896', 's111390896'] | [8892.0, 8892.0, 8892.0, 8892.0, 8952.0, 8952.0, 8952.0, 8952.0] | [22.0, 22.0, 22.0, 22.0, 28.0, 28.0, 28.0, 28.0] | [114, 114, 114, 114, 131, 131, 131, 131] |
p03072 | u952022797 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['# -*- coding: utf-8 -*-\nimport sys\nimport math\nfrom bisect import bisect_left\nfrom bisect import bisect_right\ninput = sys.stdin.readline\n\n\n\n\ndef main():\n\tN = int(input())\n\tH = input().split(" ")\n\n\tans = 0\n\tmax = 0\n\tfor i, val in enumerate(H):\n\t\tif i == 0:\n\t\t\tans += 1\n\t\t\tmax = val\n\t\t... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s301771527', 's301771527', 's301771527', 's301771527', 's126780547', 's126780547', 's126780547', 's126780547'] | [3060.0, 3060.0, 3060.0, 3060.0, 3316.0, 3316.0, 3316.0, 3316.0] | [18.0, 18.0, 18.0, 18.0, 21.0, 21.0, 21.0, 21.0] | [464, 464, 464, 464, 495, 495, 495, 495] |
p03072 | u952114288 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['input()\nms=input().split()\nc=0\nd=0\nfor m in ms:\n if m<=c:\n c=m\n d+=1\nprint(d)', 'input()\nms=input().split()\nc=0\nd=0\nfor m in ms:\n if m<=c:\n c=m\n d+=1\nprint(d)', ' input()\n ms=[int(i) for i in input().split()]\n c=0\n d=0\n for m in ms:\n if m<=c:\n c=m\n ... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Runtime Error', ... | ['s426068491', 's426068491', 's448589752', 's448589752', 's708748709', 's708748709', 's733227981', 's733227981', 's809367412', 's809367412', 's426068491', 's426068491', 's448589752', 's448589752', 's708748709', 's708748709', 's733227981', 's733227981', 's809367412', 's809367412', 's496595097', 's496595097', 's496595097... | [2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 18.0, 18.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 18.0, 18.0, 17.0, 17.0, 17.0, 17.0] | [84, 84, 138, 138, 96, 96, 95, 95, 93, 93, 84, 84, 138, 138, 96, 96, 95, 95, 93, 93, 95, 95, 95, 95] |
p03072 | u954728614 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['N = int(input())\n\nH = list(map(int, input().split()))\n\ncansee = False\ncount = 0\n\nfor i in range(N-1):\n cansee = True\n for j in range(i):\n if H[j] > H[i]:\n cansee = False\n if cansee:\n count += 1\n\nprint(count)', 'N = int(input())\n\nH = list(map(int, input().split()))\n\... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s210857025', 's210857025', 's210857025', 's210857025', 's581840206', 's581840206', 's581840206', 's581840206'] | [3060.0, 3060.0, 3060.0, 3060.0, 2940.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [241, 241, 241, 241, 229, 229, 229, 229] |
p03072 | u957872856 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['num = int(input())\nlist = [int(i) for i in input().split()]\nsum = 0\nfor j in range(num):\n list1 = list[:j+1]\n if max(list) == list1[-1]:\n sum += 1\n else:\n pass\nprint(sum)', 'num = int(input())\nlist = [int(i) for i in input().split()]\nsum = 0\nfor j in range(num):\n list1 = list[:j+1]\n if max(li... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s904738574', 's904738574', 's904738574', 's904738574', 's196157962', 's196157962', 's196157962', 's196157962'] | [3060.0, 3060.0, 3060.0, 3060.0, 3064.0, 3064.0, 3064.0, 3064.0] | [17.0, 17.0, 17.0, 17.0, 18.0, 18.0, 18.0, 18.0] | [179, 179, 179, 179, 237, 237, 237, 237] |
p03072 | u958506960 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['n = int(input())\nh = list(map(int, input().split()))\nans = 1\nfor i in range(1, n):\n for j in range(1, n):\n c = 1\n if h[i-j] <= h[i]:\n c += 1\n if c == n:\n ans += 1\nprint(ans)', 'n = int(input())\nh = list(map(int, input().split()))\nans = 1\nfor i in range(1, n):\n fo... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s226630102', 's226630102', 's226630102', 's226630102', 's488784594', 's488784594', 's488784594', 's488784594'] | [9096.0, 9096.0, 9096.0, 9096.0, 9096.0, 9096.0, 9096.0, 9096.0] | [27.0, 27.0, 27.0, 27.0, 28.0, 28.0, 28.0, 28.0] | [211, 211, 211, 211, 131, 131, 131, 131] |
p03072 | u959651981 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['N = int(input())\nH = [int(input()) for i in range(N)]\ncount = 1\nMax = H[0]\nfor i in range(1:N):\n if Max <=H[i]:\n Max = H[i]\n count += 1\n\nprint(count)\n \n', 'N = int(input())\nH = [int(input()) for i in range(N)]\ncount = 1\nMax = H[0]\nfor i in range(1:N):\n if Max <=H[i]:\n ... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s476697036', 's476697036', 's555756686', 's555756686', 's883421790', 's883421790', 's476697036', 's476697036', 's555756686', 's555756686', 's883421790', 's883421790', 's577143599', 's577143599', 's577143599', 's577143599'] | [2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 18.0, 18.0, 18.0, 18.0] | [176, 176, 174, 174, 174, 174, 176, 176, 174, 174, 174, 174, 172, 172, 172, 172] |
p03072 | u960171798 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['N = int(input()\nH = list(map(int, input().split()))\nans = 0\nfor i in range(N):\n for j in range(i):\n if H[i]>=H[j]:\n ans += 1\nprint(ans)', 'N = int(input()\nH = list(map(int, input().split()))\nans = 0\nfor i in range(N):\n for j in range(i):\n if H[i]>=H[j]:\n ans += 1\nprint(ans)', 'N = int(input()\... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s021622065', 's021622065', 's096153090', 's096153090', 's021622065', 's021622065', 's096153090', 's096153090', 's078087902', 's078087902', 's078087902', 's078087902'] | [2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [140, 140, 126, 126, 140, 140, 126, 126, 129, 129, 129, 129] |
p03072 | u960387251 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['s = int(input())\nList=list(map(int,input().split()))\na = 1\nb=List[0]\nfor i in range(s):\n if b <= List[i+1]:\n a +=1\n b = List[i+1]\nprint(a)', 's = int(input())\nList=list(map(int,input().split()))\na = 1\nb=List[0]\nfor i in range(s):\n if b <= List[i+1]:\n a +=1\n b = List[i+... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s102305142', 's102305142', 's102305142', 's102305142', 's249615948', 's249615948', 's249615948', 's249615948'] | [2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0] | [18.0, 18.0, 18.0, 18.0, 17.0, 17.0, 17.0, 17.0] | [155, 155, 155, 155, 152, 152, 152, 152] |
p03072 | u963949936 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['N = int(input())\nH = list(map(int, input().split()))\n\ncan_view = [1]\n\nfor i in range(N):\n if i == 0:\n continue\n \n count = 0\n for j in range(i):\n if H[i] > H[j]:\n count += 1\n \n if count == i:\n can_view.append(i)\n\nprint(len(can_view))', 'N = int(input()... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s281262635', 's281262635', 's281262635', 's281262635', 's727096315', 's727096315', 's727096315', 's727096315'] | [3060.0, 3060.0, 3060.0, 3060.0, 3060.0, 3060.0, 3060.0, 3060.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [282, 282, 282, 282, 284, 284, 284, 284] |
p03072 | u969848070 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['a = int(input())\nl = list(map(int, input().split()))\nfor i in range(a):\n if l[i] >= max(l[0:i]):\n c +=1\nprint(c)', 'a = int(input())\nl = list(map(int, input().split()))\nfor i in range(a):\n if l[i] >= max(l[0:i]):\n c +=1\nprint(c)', 'a = int(input())\nl = list(map(int, input().split()))\nfor i in rang... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s264388303', 's264388303', 's264388303', 's264388303', 's570679585', 's570679585', 's570679585', 's570679585'] | [2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0] | [18.0, 18.0, 18.0, 18.0, 17.0, 17.0, 17.0, 17.0] | [116, 116, 116, 116, 124, 124, 124, 124] |
p03072 | u970082363 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['n = int(input())\nhigh = [int(i) for i in input().split()]\nans = 0\nmax = 0\nfor i in range(n):\n if max>=high[i]:\n ans += 1\n max = high[i]\n\nprint(ans)', 'n = int(input())\nhigh = [int(i) for i in input().split()]\nans = 0\nmax = 0\nfor i in range(n):\n if max>=high[i]:\n ans += 1\n ... | ['Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s148382443', 's148382443', 's564478841', 's564478841', 's148382443', 's148382443', 's564478841', 's564478841', 's927296129', 's927296129', 's927296129', 's927296129'] | [2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [164, 164, 156, 156, 164, 164, 156, 156, 165, 165, 165, 165] |
p03072 | u977193988 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['N=int(input())\nH=[int(i) for i in input().split()]\nhotel=0\nfor i in range(N):\n count=0\n for k in range(i):\n if H[k]<=H[i]:\n count+=1\n continue\n \n if count==i:5\n hotel+=1\n\n\nprint(hotel)', 'N=int(input())\nH=[int(i) for i in input().split()]\nhotel=0\nfo... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s673103790', 's673103790', 's673103790', 's673103790', 's657646360', 's657646360', 's657646360', 's657646360'] | [2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0, 17.0, 18.0, 18.0, 18.0, 18.0] | [236, 236, 236, 236, 236, 236, 236, 236] |
p03072 | u979362546 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['n = int(input())\nh = list(map(int, input().split()))\ncnt = n \nh.reverse()\nfor i in h:\n for j in h:\n \tif h[j]>h[i]:\n \t\th.remove(h[i])\n \t\tcnt = cnt-1\n \telse:\n \t\th.remove(h[i])\nelse:\n print(cnt)', 'n = int(input())\nh = list(map(int, input().split()))\ncnt = n \nh.reverse()\nfor ... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s694299711', 's694299711', 's857559834', 's857559834', 's694299711', 's694299711', 's857559834', 's857559834', 's050117475', 's050117475', 's050117475', 's050117475'] | [3064.0, 3064.0, 2940.0, 2940.0, 3064.0, 3064.0, 2940.0, 2940.0, 3060.0, 3060.0, 3060.0, 3060.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 18.0, 18.0, 18.0, 18.0] | [212, 212, 167, 167, 212, 212, 167, 167, 167, 167, 167, 167] |
p03072 | u981332890 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['N = int(intput())\nH = list(map(int, input().split()))\n\npre = 0\nans = 0\n\nfor h in H:\n if h >= pre:\n pre = h\n ans += 1\nprint(ans)', 'N = int(intput())\nH = list(map(int, input().split()))\n\npre = 0\nans = 0\n\nfor h in H:\n if h >= pre:\n pre = h\n ans += 1\nprint(ans)', 'N = int(intput())\nH =... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s209794137', 's209794137', 's209794137', 's209794137', 's251302368', 's251302368', 's251302368', 's251302368'] | [2940.0, 2940.0, 2940.0, 2940.0, 3060.0, 3060.0, 3060.0, 3060.0] | [17.0, 17.0, 17.0, 17.0, 19.0, 19.0, 19.0, 19.0] | [134, 134, 134, 134, 135, 135, 135, 135] |
p03072 | u981853376 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['h_list = map(int, input().split())\na = 0\nb = 0\nfor h in h_list:\n if h >= b:\n b = h\n a += 1\nprint(a)\n', 'h_list = map(int, input().split())\na = 0\nb = 0\nfor h in h_list:\n if h >= b:\n b = h\n a += 1\nprint(a)\n', 'h_list = map(int, input().split())\na = 0\nb = 0\nfor h in h_list:\n if h <= b:... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s006631382', 's006631382', 's481362350', 's481362350', 's642656529', 's642656529', 's006631382', 's006631382', 's481362350', 's481362350', 's642656529', 's642656529', 's652379216', 's652379216', 's652379216', 's652379216'] | [2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0, 17.0, 18.0, 18.0, 17.0, 17.0, 17.0, 17.0, 18.0, 18.0, 18.0, 18.0, 18.0, 18.0] | [107, 107, 107, 107, 101, 101, 107, 107, 107, 107, 101, 101, 113, 113, 113, 113] |
p03072 | u982198202 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['N = input().split()\nprint(N)\nh = 1\nfor i in range(1,len(N)):\n for j in range(i):\n if (N[i] < N[j]):\n break\n if j == i-1:\n h += 1\nprint(h)', 'N = input().split()\nprint(N)\nh = 1\nfor i in range(1,len(N)):\n for j in range(i):\n if (N[i] < N[j]):\n b... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s430723978', 's430723978', 's430723978', 's430723978', 's308320856', 's308320856', 's308320856', 's308320856'] | [2940.0, 2940.0, 2940.0, 2940.0, 3060.0, 3060.0, 3060.0, 3060.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [176, 176, 176, 176, 393, 393, 393, 393] |
p03072 | u991075981 | 2,000 | 1,048,576 | There are N mountains ranging from east to west, and an ocean to the west. At the top of each mountain, there is an inn. You have decided to choose where to stay from these inns. The height of the i-th mountain from the west is H_i. You can certainly see the ocean from the inn at the top of the westmost mountain. F... | ['n = int(input())\nh = list(map(int, input().split()))\n\ncount = 1\nmax = 0\nfor i in range(n-1):\n if max < h[i]:\n max = h[i]\n\n print(max)\n if max <= h[i+1]:\n count += 1\n\nprint(count)\n', 'n = int(input())\nh = list(map(int, input().split()))\n\ncount = 1\nmax = 0\nfor i in range(n-1):\... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted', 'Accepted', 'Accepted', 'Accepted'] | ['s355909376', 's355909376', 's355909376', 's355909376', 's356120687', 's356120687', 's356120687', 's356120687'] | [2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0, 2940.0] | [18.0, 18.0, 18.0, 18.0, 17.0, 17.0, 17.0, 17.0] | [202, 202, 202, 202, 187, 187, 187, 187] |
p03073 | u003501233 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['s=input()\n\nBW=s[::2]\nWB=s[1::2]\n\nx=BW.count("0") + WB.count("1")\ny=BW.count("0") + WB.count("1")\n\nprint(min(x,y))', 's=input()\n\nBW=s[::2]\nWB=s[1::2]\n\nx=BW.count("0") + WB.count("1")\ny=BW.count("1") + WB.count("0")\n\nprint(min(x,y))'] | ['Wrong Answer', 'Accepted'] | ['s803943104', 's382032861'] | [3188.0, 3188.0] | [19.0, 18.0] | [113, 113] |
p03073 | u003581113 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ["S = input()\nN = len(S)\n\nA1 = '0'\nA2 = '1'\nfor i in range(1, N):\n if i // 2 == 1:\n A1 = A1 + '0'\n A2 = A2 + '1'\n else:\n A1 = A1 + '1'\n A2 = A2 + '0'\nS = int(S, 2)\nA1 = int(A1, 2)\nA2 = int(A2, 2)\nn1 = S ^ A1\nn2 = S ^ A2\nprint(min(n1, n2))", "S = input()\nN = len(S)\n\nA1 = '0'\nA2 = '1'\n... | ['Wrong Answer', 'Accepted'] | ['s967578541', 's722946096'] | [3440.0, 3316.0] | [71.0, 59.0] | [250, 281] |
p03073 | u013605408 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['c2,c3 = 0,0\ndef ret(a,b,c):\n global c2,c3\n if a == b:\n if c == 2:\n c2 += 1\n else:\n c3 += 1\n if b == "0":\n return "1"\n else:\n return "0"\n else:\n return b\nS = input()\nS2,S3 = list(S),list(S)\ndefault = S2[0]\nfor j,k in enumerate(S2):\n if j == 0:\n continue\n S... | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s630145130', 's818301668', 's937943587'] | [137256.0, 2940.0, 4852.0] | [1768.0, 17.0, 116.0] | [480, 448, 450] |
p03073 | u020812754 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ["#coding:utf-8\n\nS = input()\n\nN = len(S)\nans = 0\nSR = []\nif S[0] == '0':\n\tfor i in range(int(N/2)):\n\t\tSR.append('0')\n\t\tSR.append('1')\nelse:\n\tfor i in range(int(N/2)):\n\t\tSR.append('1')\n\t\tSR.append('0')\n\nfor i in range(N):\n\tif S[i] != SR[i]:\n\t\tans += 1\n\t\t\nprint(ans)\n\t\t\t\n", "#coding... | ['Runtime Error', 'Accepted'] | ['s029728347', 's712936609'] | [3956.0, 4724.0] | [48.0, 56.0] | [267, 247] |
p03073 | u022871813 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ["s = input()\nif len(s) == 1:\n print(0)\nelse:\n r = 0\n f = s[0]\n for i in s[1:]:\n if i == f:\n r += 1\n \tf = '1' if i == '0' else '0'\n f = i\n print(r)", "s = input()\nif len(s) == 1:\n print(0)\nelse:\n r = 0\n f = s[0]\n for i in s[1:]:\n if i ... | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s163233588', 's915806070', 's663747698'] | [2940.0, 3064.0, 3188.0] | [17.0, 17.0, 38.0] | [192, 205, 210] |
p03073 | u035268040 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['n = str(input())\nn_arr = list(str(n))\narr = list(map(int, n_arr))\nprint(arr)\nzero = []\none = []\nfor i in range(len(arr)):\n if i % 2 == 0:\n zero.append(0)\n one.append(1)\n else:\n zero.append(1)\n one.append(0)\nzero_diff = 0\none_diff = 0\nfor i in range(len(arr)):\n if a... | ['Wrong Answer', 'Accepted'] | ['s206258450', 's113545345'] | [6948.0, 6432.0] | [106.0, 101.0] | [448, 437] |
p03073 | u035856025 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['s = [int(i) for i in list(input())]\ncount = 0\n\nfor i in range(1,len(s)-1):\n a = s[i-1:i+2]\n if a[-1] == a[0] == a[1]:\n s[i] = 1\nprint(s)\n', 's = input()\ncount_odd = 0\nfor i in range(len(s)): \n if s[i] != str(i % 2):\n count_odd += 1\ncount_even = 0\nfor i in range(len(s)):\n if s[... | ['Wrong Answer', 'Accepted'] | ['s628644712', 's821676723'] | [4652.0, 3188.0] | [97.0, 102.0] | [150, 251] |
p03073 | u037074041 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['from sys import stdin\nimport math\nimport itertools\n\n\ndef makeIntMatrix(lines):\n intMatrix = []\n for a in makeStringMatrix(lines):\n intMatrix.append([int(b) for b in a])\n return intMatrix\n \n \ndef makeStringMatrix(lines):\n stringMatrix = [line.split() for line in lines]\n return strin... | ['Wrong Answer', 'Accepted'] | ['s824290703', 's673757026'] | [4944.0, 4084.0] | [113.0, 46.0] | [867, 1076] |
p03073 | u038408819 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ["s = list(input())\ns1 = []\ns2 = []\nfor i in range(len(s)):\n if i % 2 == 0:\n s1.append('0')\n s2.append('1')\n else:\n s1.append('1')\n s2.append('0')\nprint(min(min_1, min_2))", "s = list(input())\ns1 = []\ns2 = []\nfor i in range(len(s)):\n if i % 2 == 0:\n s1.append('... | ['Runtime Error', 'Accepted'] | ['s117864846', 's712357331'] | [5512.0, 5512.0] | [47.0, 87.0] | [203, 382] |
p03073 | u038815010 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['s=input()\nn=len(s)\nfor i in range(n-1):\n if s[i]=="0" and i%2==0:\n ans+=1\n elif s[i]=="1" and i%2==1:\n ans+=1\nans1=0\nfor i in range(n-1):\n if s[i]=="1" and i%2==0:\n ans1+=1\n elif s[i]=="0" and i%2==1:\n ans1+=1\n\nprint(min(ans,ans1))A', 's=input()\nn=len(s)\nans=0\n... | ['Runtime Error', 'Accepted'] | ['s208364716', 's349594547'] | [3064.0, 3188.0] | [17.0, 76.0] | [272, 273] |
p03073 | u046585946 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['s=list(input())\ncount1=0\ncount2=0\nfor i in range(len(s)):\n if s[i]==s[i+1]:\n count1=count1+1\nfor i in range(1,len(s)):\n if s[i]==s[i+1]:\n count2=count2+1\nif count1>=count2:\n print(count1)\nelse:\n print(count2)', 's=list(input())\ncount1=0\ncount2=0\nfor i in range(len(s)-1):\n if s[i]==s[i+1]:\n... | ['Runtime Error', 'Wrong Answer', 'Accepted'] | ['s126339893', 's954691678', 's861744441'] | [3956.0, 3956.0, 3956.0] | [45.0, 68.0, 68.0] | [218, 222, 370] |
p03073 | u056544471 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ["S = input().rstrip()\ns = list(S)\nprint(s)\nN = len(S)\nc = 0\nif N == 1:\n print(0)\nelse:\n for i in range(1,N)\n \tif S[i-1] == '0' and S[i] == '0':\n S[i] = 1\n c +=1\n elif S[i-1] == '1' and S[i] == '1':\n S[i] = 0\n c +=1\nprint(c)", "S = input().rstrip()\ns = list(S)\nN = len(S)\nc =... | ['Runtime Error', 'Accepted'] | ['s967945238', 's847830319'] | [2940.0, 4852.0] | [19.0, 70.0] | [248, 393] |
p03073 | u058300412 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ["S = input().strip()\nansB = 0\nansW = 0\nfor i,c in emumerate(S):\n if (i % 2 == 0):\n if (c == '0'):\n ansW += 1\n else:\n \tif (c == '1'):\n ansB += 1\n\nans = min(ansW, ansB)\nprint(ans)", "S = input().strip()\nansB = 0\nansW = 0\nfor i,c in enumerate(S):\n\tif (i % 2 == 0):\n\t\tif (c == '0'):\n\... | ['Runtime Error', 'Accepted'] | ['s832801568', 's650715111'] | [3064.0, 3188.0] | [18.0, 47.0] | [193, 222] |
p03073 | u062459048 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['S = list(map(int, input().split()))\n\nl = len(S)\nc1 = 0 \nc2 = 0\n\nfor i in range(l):\n if i%2 ==0:\n if S[i] == 0:\n c1 += 1\n else:\n c2 += 1\n else:\n if S[i] == 0:\n c2 += 1\n else:\n c1 += 1\n \nprint(min(c1,c2))', 'S = list(map(int, input().split()))\n\nl = len(S)\nc1 = 0... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s153614934', 's503034970', 's635488914'] | [3188.0, 3188.0, 3956.0] | [86.0, 86.0, 47.0] | [239, 201, 226] |
p03073 | u067694718 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['s = input()\nn = len(s)\n\na = "10" * (n // 2) + ("1" if n % 2 == 0 or n == 1 else "")\nb = "01" * (n // 2) + ("0" if n % 2 == 0 or n == 1 else "")\n\nsum_a = 0\nfor i in range(n):\n if s[i] != a[i]: sum_a += 1\n\nsum_b = 0\nfor i in range(n):\n if s[i] != b[i]: sum_b += 1\n\nprint(min(sum_a, sum_b))', 's = inp... | ['Runtime Error', 'Accepted'] | ['s383458363', 's767180738'] | [3316.0, 3316.0] | [65.0, 62.0] | [293, 273] |
p03073 | u069172538 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['S =input()\nl=len(S)\nN=int(S,2)\n\n \napopcount=0\nbpopcount=0\nfor i in range(0,l):\n if i%2==0:\n if (N & 0b10**i)!=0:\n \t\tapopcount+=1\n else:\n \tbpopcount+=1\n else:\n if (N & 0b10**i)!=0:\n \tbpopcount+=1\n else:\n \tapopcount+=1\nprint(apopcount,bpopcount)\nif apopcount<bpopc... | ['Wrong Answer', 'Accepted'] | ['s775346096', 's552411128'] | [3188.0, 3188.0] | [2104.0, 74.0] | [338, 292] |
p03073 | u072949274 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ["cnt_st0 = 0\ncnt_st1 = 0\nin_str = str(input())\nfor i, m in enumerate(in_str):\n if i % 2 == 0:\n if m == '0':\n cnt_st1 += 1\n else:\n cnt_st0 += 1\n else:\n if m == '0':\n cnt_st0 += 1\n else:\n cnt_st1 += 1\n \nprint(min(cnt_st0, cnt_St1))", "cnt_st0 = 0\ncnt_st1 = 0\nin_str... | ['Runtime Error', 'Accepted'] | ['s819033751', 's428620574'] | [3316.0, 3188.0] | [47.0, 59.0] | [267, 270] |
p03073 | u079022116 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ["s=input()\nsento1 = 0\nsento0 = 0\nfor i in range(len(s)):\n\n if i % 2 == 0:\n \n if s[i] == '1':\n sento1 += 1\n \n elif s[i] == '0':\n sento0 += 1\n \n else:\n if s[i] == '0':\n sento1 += 1\n elif s[i] == '1'\n sento0 += 1\n \nprint(min(sento1,sento0))", "s=input... | ['Runtime Error', 'Accepted'] | ['s404359873', 's023975699'] | [2940.0, 3188.0] | [17.0, 59.0] | [288, 290] |
p03073 | u089668660 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\nS = input()\nlis = []\nfor t in range(len(S)):\n lis.append(S[t])\nevencount0 = 0\nunevencount0 = 0\nevencount1 = 0\nunevencount1 = 0\nif len(S)%2 == 0:\n for t in range(int(len(S)/2)):\n if S[2*t + 1] == "0":\n evencount0 += 1\n evencount1 =... | ['Wrong Answer', 'Accepted'] | ['s163243024', 's260181983'] | [4092.0, 4096.0] | [56.0, 54.0] | [979, 988] |
p03073 | u102731033 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['s = list(map(int,input()))\nprint(s)\nn = len(s)\ncount1 = 0\ncount2 = 0\nif n == 1:\n print(0) \nelse:\n for i in range(n):\n if i % 2 == 0 and s[i] != 0:\n count1 += 1\n elif i%2 !=0 and s[i] != 1:\n count1 += 1\n for i in range(n):\n if i % 2 == 0 and s[i] != 1:\... | ['Wrong Answer', 'Accepted'] | ['s453250475', 's233331743'] | [4768.0, 3956.0] | [101.0, 95.0] | [417, 405] |
p03073 | u104282757 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['S = list(input())\n\nres_10 = 0\nres_01 = 0\n\nfor i in range(N):\n if i % 2 == 0:\n if S[i] == "0":\n res_10 += 1\n else:\n res_01 += 1\n else:\n if S[i] == "1":\n res_10 += 1\n else:\n res_01 += 1\nprint(min(res_10, res_01))', 'S = list(i... | ['Runtime Error', 'Accepted'] | ['s949970659', 's573707502'] | [3956.0, 3956.0] | [19.0, 49.0] | [288, 295] |
p03073 | u106103668 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['def resolve():\n S = input()\n s1 = S[::2]\n s2 = S[1::2]\n print()\n print(s1)\n print(s2)\n for i in range(len(S)):\n continue\n for i in range(len(S)):\n continue\n for i in range(len(S)):\n continue\n for i in range(len(S)):\n continue\n print("1")\n\nr... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s530201845', 's680573946', 's778768020'] | [3316.0, 3316.0, 5420.0] | [28.0, 28.0, 39.0] | [310, 247, 184] |
p03073 | u107091170 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['s=list(input())\ndp=[[0,0] for i in range(len(s)+1)]\ndp[0][1] = 1\nfor i in range( len(s)-1 ):\n if s[i] == s[i+1]:\n dp[i+1][0] = dp[i][1]\n dp[i+1][1] = dp[i][0]+1\n else:\n dp[i+1][0] = dp[i][0]\n dp[i+1][1] = dp[i][1]+1\n print(dp[i+1])\nprint(min(dp[len(s)-1]))\n', 's=list(input())\ndp=[[0,0] for... | ['Wrong Answer', 'Accepted'] | ['s364734231', 's906324359'] | [18728.0, 17288.0] | [242.0, 118.0] | [272, 256] |
p03073 | u116233709 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['s=list(input())\nx=0\ny=0\nfor i in range(0,len(s)):\n if i%2==0:\n if s[i]=="0":\n x+=1\n else:\n if s[i]=="1":\n x+=1\n \nfor j in range(0,len(s)):\n if i%2==0:\n if s[i]=="1":\n y+=1\n else:\n if s[i]=="0":\n y+=1\n \nprint(min(x,y)) \n ', 's=list(input())\nx=0\n... | ['Wrong Answer', 'Accepted'] | ['s151340633', 's939439554'] | [3956.0, 3956.0] | [65.0, 69.0] | [272, 273] |
p03073 | u123745130 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['s=input()\nans=len(s)\nfor i in range(2):\n cnt=0\n for j in s:\n if int(j) % 2 == 0 and j!=i: cnt+=1\n if int(j) % 2 == 1 and j==i: cnt+=1\n ans=min(cnt,ans)\nprint(ans)', 's=input()\nans=len(s)\nfor i in range(2):\n cnt=0\n for j in range(len(s)):\n if j % 2 == 0 and s[j]!=str(i): cnt+=1\n if j % 2... | ['Wrong Answer', 'Accepted'] | ['s028106189', 's829154205'] | [3188.0, 3188.0] | [134.0, 125.0] | [171, 189] |
p03073 | u123824541 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['import numpy\n\ns = list(input())\nN = len(s)\ncount_A = 0\ncount_B = 0\n\nfor i in range(N):\n s[i] = int(str(s[i]))\n\nA = numpy.empty(N)\nB = numpy.empty(N)\n\nfor j in range(N):\n if j % 2 == 0 :\n A[j] = 1\n B[j] = 0\n else:\n A[j] = 0\n B[j] = 1\n\nfor k in range(N):\n A[... | ['Wrong Answer', 'Accepted'] | ['s565143308', 's456543872'] | [17076.0, 15028.0] | [730.0, 737.0] | [515, 496] |
p03073 | u128999728 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ["#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n\nn = str(input())\nl1 = []\nfor c in n:\n\tl1.append(c)\n\nz, o = '0', '1'\n\none, zero = [], []\n\nfor i in range(len(l1)):\n\tif i%2 == 0:\n\t\tone.append(o)\n\t\tzero.append(z)\n\telse:\n\t\tone.append(z)\n\t\tzero.append(o)\n\nc1, c2 = 0,0\nfor i in range(len(l1))... | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s292799066', 's765364750', 's664789951'] | [5660.0, 5664.0, 5616.0] | [61.0, 61.0, 95.0] | [378, 387, 380] |
p03073 | u130617211 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['# coding=utf-8\n\ntile = input()\n\ncor_list = ["10"*50000, "01"*50000]\n\ndiff_1 = int("0b"+tile, 2) ^ int("0b"+cor_list[0][:len(tile)], 2) \ndiff_2 = int("0b"+tile, 2) ^ int("0b"+cor_list[1][:len(tile)], 2)\n\nscore_1 = sum([int(s) for s in bin(diff_1)[2:]])\nscore_2 = sum([int(s) for s in bin(diff_2)[2:]])\nprint... | ['Runtime Error', 'Accepted'] | ['s024158372', 's715609191'] | [4492.0, 4492.0] | [54.0, 61.0] | [330, 321] |
p03073 | u135116520 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['S=input()\ns=0\nt=0\nfor i in range(len(S)):\n if i%2==0 and S[i]==0:\n s+=1\nfor j in range(len(S)):\n if i%2==0 and S[i]==1:\n t+=1\nprint(min(s,t))', 'S=input()\na=len(S)\ns=0\nt=0\nfor i in range(a):\n if i%2==0 and S[i]==1:\n s=s\n elif i%2==0 and S[i]==0:\n s+=1\n elif i%2!=0 and S[i]==0:\n ... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s020626070', 's163972011', 's419616410', 's426397125', 's805688280', 's810941075', 's894444684'] | [3188.0, 3188.0, 3188.0, 3188.0, 3956.0, 3188.0, 3188.0] | [47.0, 112.0, 55.0, 134.0, 126.0, 102.0, 79.0] | [149, 326, 231, 300, 310, 321, 229] |
p03073 | u140480594 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['S = list(str(input()))\nif S[0] == "1":\n for i, j in enumerate(S):\n if i % 2 == 0 and j == "0":\n S[i] = "1"\n elif i % 2 == 1 and j == "1":\n S[i] = "0"\nelse:\n for i, j in enumerate(S):\n if i % 2 == 0 and j == "1":\n S[i] = "0"\n elif i % 2 == 1... | ['Wrong Answer', 'Accepted'] | ['s716436721', 's648668143'] | [5416.0, 3956.0] | [55.0, 49.0] | [353, 367] |
p03073 | u143051858 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ["cnt = 0\nnum = '1'\n s = input()\n for i in range(len(s)):\n if s[i] == num:\n cnt += 1\n if num == '1':\n num = '0'\n else:\n num = '1'\n print(min(int(len(s)-cnt),cnt))", "cnt = 0\nnum = '1'\ns = input()\nfor i in range(len(s)):\n if s[i] == num:\n ... | ['Runtime Error', 'Accepted'] | ['s599495109', 's663740934'] | [2940.0, 3188.0] | [17.0, 41.0] | [223, 187] |
p03073 | u146597538 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['s = list(input())\npattern_a_count = 0\npattern_b_count = 0\n\nfor index, value in enumerate(s):\n if index % 2 == 0:\n if value == 0:\n pattern_a_count += 1\n if index % 2 == 1:\n if value == 1:\n pattern_a_count += 1\n \nfor index, value in enumerate(s):\n if index % 2 == 0:\n if value ==... | ['Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Runtime Error', 'Accepted'] | ['s159091793', 's198577362', 's294446271', 's361719659', 's405544311', 's882407561', 's015934678'] | [3956.0, 3956.0, 2940.0, 2940.0, 3956.0, 2940.0, 3956.0] | [77.0, 79.0, 17.0, 17.0, 77.0, 17.0, 83.0] | [516, 524, 409, 524, 524, 516, 532] |
p03073 | u152614052 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['import collections\ns = input()\nc1 = s.count("1")\nc0 = s.count("0")\n\nprint(min(c1,c0))', 's = list(input())\nans = 0\nif len(s) == 1:\n pass\nelse:\n for i in range(1,len(s)):\n if s[i] == s[i-1]:\n ans += 1\n if s[i] == "1":\n s[i] = "0"\n else:\n ... | ['Wrong Answer', 'Accepted'] | ['s779063650', 's164978375'] | [3444.0, 3956.0] | [21.0, 51.0] | [85, 246] |
p03073 | u167681750 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['s = input()\no1e0 = 0\no0e1 = 0\n\nfor n, i in enumerate(s):\n print(n,i)\n if (n // 2 == 0):\n if (i == "0"):\n o1e0 += 1\n else:\n o0e1 += 1\n\n else:\n if (i == "1"):\n o1e0 += 1\n else:\n o0e1 += 1\n \nprint(min(len(s) - o... | ['Wrong Answer', 'Accepted'] | ['s593458649', 's767564344'] | [4308.0, 3188.0] | [164.0, 47.0] | [320, 286] |
p03073 | u169138653 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ["s=input()\nw=str()\nb=str()\ncnt1=0\ncnt2=0\nfor i in range(n):\n if i%2==0:\n w+='1'\n b+='0'\n else:\n w+='0'\n b+='1'\nfor i in range(n):\n if s[i]!=w[i]:\n cnt1+=1\n if s[i]!=b[i]:\n cnt2+=1\nprint(min(cnt1,cnt2))", "s=input()\nw=str()\nb=str()\ncnt1=0\ncnt2=0... | ['Runtime Error', 'Accepted'] | ['s846925714', 's688347927'] | [3188.0, 3316.0] | [18.0, 101.0] | [254, 265] |
p03073 | u170183831 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ["s = input()\nc0 = 0\nc1 = 0\nfor i in range(s):\n if i % 2 == 0:\n if s[i] != '0':\n c0 += 1\n if s[i] != '1':\n c1 += 1\n else:\n if s[i] != '1':\n c0 += 1\n if s[i] != '0':\n c1 += 1\nprint(min(c0, c1))", "s = input()\nc0 = 0\nc1 = 0\nfor i in range(len(s)):\n if i % 2 == 0:\n ... | ['Runtime Error', 'Accepted'] | ['s377680296', 's097239647'] | [3188.0, 3188.0] | [17.0, 53.0] | [224, 230] |
p03073 | u172111219 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['import math\nn = int(input())\nnum = [int(input()) for i in range(5)]\nprint(int(4+math.ceil(n/min(min(num)))))', 'import numpy as np\ns = [int(i) for i in input()]\n\nn = len(s)\n\nlist01 = [int(i%2) for i in range(n)]\nlist10 = [int((i+1)%2) for i in range(n)]\n\n \nlist_a = np.array(s) - np.array(list01)\nl... | ['Runtime Error', 'Accepted'] | ['s503958351', 's357052312'] | [3188.0, 17868.0] | [86.0, 246.0] | [108, 344] |
p03073 | u180528413 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ["S = input()\nword_01 = '01'\nword_10 = '10'\nq, mod = divmod(len(S), 2)\nif mod == 0:\n word_01 = word_01 * q\n word_10 = word_10 * q\nelse:\n word_01 = word_01 * (q-1) + '0'\n word_10 = word_10 * (q-1) + '1'\nS_list = list(S)\nword_01_list = list(word_01)\nword_10_list = list(word_10)\ncounter1 = 0\ncoun... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s123070998', 's917821321', 's699766082'] | [5620.0, 5936.0, 5620.0] | [53.0, 55.0, 54.0] | [510, 532, 502] |
p03073 | u187857228 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['def test():\n s = list(map(int,list(input())))\n for i in range(len(s)-1):\n if s[i] == s[i+1]:\n s[i+1] ^= 1\n print(s) \n\n\nif __name__ == "__main__":\n test()\n', 'def test():\n s = list(map(int,list(input())))\n count = 0\n for i in range(len(s)-1):\n if s[i] == s[i+... | ['Wrong Answer', 'Accepted'] | ['s445641190', 's242110806'] | [4652.0, 4652.0] | [55.0, 49.0] | [184, 224] |
p03073 | u189188797 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ["n = input()\nanswer = 0\nif len(n)<=1:\n print(0)\nelse:\n for i in range(1,len(n)):\n if n[i]==n[i-1]:\n answer+=1\n if n[i]=='0':\n n = n[:i]+'1'+n[i+1:]\n else:\n n = n[:i]+'0'+n[i+1:]\n print(answer)\nprint(n)", "n = input()\nanswer = ... | ['Wrong Answer', 'Accepted'] | ['s524377176', 's367212469'] | [3444.0, 3432.0] | [841.0, 801.0] | [279, 263] |
p03073 | u189487046 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['s = input()\nodd = s[0::2]\neven = s[1::2]\n\nodd0 = odd.count("0")\nodd1 = odd.count("1")\neven0 = even.count("0")\neven1 = even.count("1")\n\nprint(max((odd0 + even1), (odd1 + even0)))\n', 's = input()\nodd = s[0::2]\neven = s[1::2]\n\nodd0 = odd.count("0")\nodd1 = odd.count("1")\neven0 = even.count("0")\neven1 = e... | ['Wrong Answer', 'Accepted'] | ['s279243697', 's463339310'] | [3188.0, 3188.0] | [18.0, 18.0] | [178, 178] |
p03073 | u191874006 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['#!/usr/bin/env python3\n\nimport re\n\na = input()\n\npreans1 = 0\npreans2 = 0\nif(a[0] == "0"):\n for i in range(1,len(a)):\n if(i%2 == 0):\n if(a[i] != "1"):\n preans1 += 1\n elif(i%2 == 1):\n if(a[i] != "0"):\n preans1 += 1\n if(a[-1] == "1"):... | ['Wrong Answer', 'Accepted'] | ['s058479413', 's345379166'] | [3316.0, 3316.0] | [79.0, 72.0] | [1011, 1053] |
p03073 | u193598069 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['S = input()\nwb = ["0" if i % 2 == 0 else "1" for i in range(len(S))]\nbw = ["1" if i % 2 == 0 else "0" for i in range(len(S))]\n\ncnt_wb = 0\ncnt_bw = 0\nfor i in range((len(S))):\n if wb[i] != S[i]:\n cnt_wb += 1\n if bw[i] != S[i]:\n cnt_bw += 1\n \nprint (min(cnt_eb, cnt_bw))', 'S = input()\nwb = ["0" ... | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s144423244', 's331846116', 's416527326'] | [4724.0, 4852.0, 4724.0] | [83.0, 38.0, 78.0] | [279, 280, 279] |
p03073 | u197394058 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ["a =list(input())\n\n\ndef saisyo1(a):\n kisuu = a[1::2]\n guusuu = a[0::2]\n count = 0\n for i in kisuu:\n if i != 1:\n count += 1\n for i in guusuu:\n if i != 0:\n count += 1\n return count\n\ndef saisyo0(a):\n kisuu = a[1::2]\n guusuu = a[0::2]\n count ... | ['Wrong Answer', 'Accepted'] | ['s460545739', 's005775879'] | [4652.0, 4652.0] | [36.0, 31.0] | [535, 545] |
p03073 | u200346982 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['s = input()\nl = len(s)\n\ns1 = [ ((-1)^i + 1)/2 for i in range(l)]\ns2 = [ ((-1)^(i+1) + 1)/2 for i in range(l)]\n\nm = 0\nn = 0\nfor i in range(l):\n m += (s[i] - s1[i])^2\n n += (s[i] - s2[i])^2\n\nprint(min(m,n))', 's = list(map(int, input().split()))\nl = len(s)\n\ns1 = [ ((-1)^i + 1)/2 for i in range(l)]\ns2 ... | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s453249225', 's645113663', 's401312206'] | [9460.0, 3188.0, 4852.0] | [52.0, 86.0, 229.0] | [206, 230, 224] |
p03073 | u201449687 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['tiles = map(int, input())\n# inputs = "10010010"\n\n\n\ndef count_repaint_tiles(tiles):\n if len(tiles) == 0:\n return 0\n counts = 0\n color = tiles[0]\n for tile in tiles[1:]:\n counts = counts + 1 if tile != color else 0\n color = 1 - color\n return counts\n\n\nprint(count_repai... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted'] | ['s084857528', 's132785223', 's838534313', 's787209885'] | [3188.0, 2940.0, 3188.0, 4640.0] | [18.0, 17.0, 18.0, 38.0] | [351, 365, 359, 363] |
p03073 | u202406075 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['import numpy as np\n\ns_ = int(input())\ns = np.array(list(map(int, str(s_))))\n\na01 = np.tile([0,1], len(s)//2+1)\na10 = np.tile([1,0], len(s)//2+1)\n\nif len(s)%2 != 0:\n a01 = np.delete(a01, len(s))\n a10 = np.delete(a10, len(s))\nelse:\n a01 = np.delete(a01, [len(s)-1,len(s)])\n a10 = np.delete(a10, ... | ['Wrong Answer', 'Accepted'] | ['s594258947', 's239417975'] | [17216.0, 17108.0] | [489.0, 263.0] | [450, 324] |
p03073 | u211259428 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['S = str(input())\nN = len(S)\n\nleft_b = 0\nif N%2 == 0:\n for i in range(N//2 - 1):\n if S[2*i] == str(1): \n left_b = left_b + 1\n if S[2*i+1] == str(0):\n left_b = left_b + 1\n mini = min(left_b,N - left_b)\n \nelse:\n for i in range(N//2 - 1):\n if S[2*i]... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s025587532', 's068819881', 's479330889', 's062061968'] | [3188.0, 3680.0, 3188.0, 3188.0] | [55.0, 88.0, 61.0, 63.0] | [626, 643, 626, 628] |
p03073 | u214434454 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['s = input()\nfor i in range(1,len(s)):\n if s[i-1] == "0" and s[i] == s[i-1]:\n s = s[:i] + "1" + s[i+1:]\n elif s[i-1] == "1" and s[i] == s[i-1]:\n s = s[:i] + "0" + s[i+1:]\nprint(s)', 's = input()\ncount = 0\nfor i in range(1,len(s)):\n if s[i-1] == "0" and s[i] == s[i-1]:\n s = s[:i]... | ['Wrong Answer', 'Accepted'] | ['s166605387', 's863551359'] | [3480.0, 3436.0] | [783.0, 814.0] | [198, 250] |
p03073 | u215726277 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['S = input()\n\na = "0b"\nfor i in range(len(S)):\n if i % 2 == 0:\n a += "0"\n else:\n a += "1"\na = int(a, 2)\nb = "0b"\nfor i in range(len(S)):\n if i % 2 == 0:\n b += "1"\n else:\n b += "0"\nb = int(b, 2)\nS = int("0b"+S, 2)\nS_a = S ^ a\nS_b = S ^ b\nprint(bin(S_a).count("1... | ['Wrong Answer', 'Accepted'] | ['s941119975', 's410568826'] | [3316.0, 3316.0] | [70.0, 71.0] | [373, 373] |
p03073 | u219503971 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ["s = '9' + input()\nt = len(s) - 1\nA = '9' + '01'*int(t/2) + '0'*int(t%2)\nB = '9' + '10'*int(t/2) + '1'*int(t%2)\n\ns = int(s)\nA = int(A)\nB = int(B)\n\nsa = s^A\nsa = sa.count('1')\nsb = s^B\nsb = sb.count('1')\n\nif sa >= sb:\n print(sa)\nelse:\n print(sb)", "s = '9' + input()\nt = len(s)\nA = '9' + '01'*in... | ['Runtime Error', 'Runtime Error', 'Wrong Answer', 'Accepted'] | ['s255086196', 's305716009', 's624248890', 's205621520'] | [3444.0, 3444.0, 3316.0, 3316.0] | [223.0, 221.0, 52.0, 54.0] | [249, 245, 252, 252] |
p03073 | u239528020 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['import numpy as np\nH = input()\nH = str.split(H)\nH = np.array(H, int)\nx = []\ny = []\nfor i in range(len(H)):\n x.append(i%2)\n y.append((i+1)//2)\nprint(H == np.array(x))\nprint(H == np.array(y))\na = sum(H == np.array(x))\nb = sum(H == np.array(y))\n\nif(a>=b):\n print(len(H)-a)\nelse:\n print(len(H)... | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s671328898', 's907714190', 's904683664'] | [13020.0, 3188.0, 18252.0] | [219.0, 17.0, 924.0] | [304, 285, 377] |
p03073 | u243572357 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ["a = input()\nb = a[::2].index('0') + a[1::2].index('1')\nc = min(b, len(a) - b)\nprint(c)", "a = list(input())\nb = a[::2].index('0') + a[1::2].index('1')\nc = min(b, len(a) - b)\nprint(c)\n", "a = list(input())\nb = a[::2].count('0') + a[1::2].count('1')\nc = min(b, len(a) - b)\nprint(c)\n"] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s177209722', 's422030970', 's255280641'] | [3188.0, 4268.0, 4268.0] | [17.0, 20.0, 21.0] | [86, 93, 93] |
p03073 | u244836567 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['a=input()\nb=int(len(a))\nc=0\nd=0\nfor i in range(b):\n if a[2*i]==1:\n c=c+1\n if a[2*1+1]==0:\n c=c+1\nfor i in range(b):\n if a[2*i]==0:\n d=d+1\n if a[2*1+1]==1:\n d=d+1\nif c>d:\n print(d)\nelse:\n print(c)', 'a=input()\nb=int(len(a))\nc=0\nd=0\nif b%2==0:\n for i in range(b//2):\n if a[2*... | ['Runtime Error', 'Accepted'] | ['s605546782', 's043073519'] | [9216.0, 9240.0] | [36.0, 57.0] | [213, 555] |
p03073 | u246253778 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['S = input()\nli = []\nfor s in S:\n li.append(int(s))\n\ncount = 0\nfirst = li[0]i\nfor i in range(len(li)):\n if i % 2 == 0:\n if li[i] != first:\n count += 1\n else:\n if li[i] == first:\n count += 1\n\ncount2 = 1\nfor i in range(len(li)):\n if i % 2 == 0:\n if... | ['Runtime Error', 'Accepted'] | ['s705830139', 's827671457'] | [2940.0, 4084.0] | [17.0, 101.0] | [426, 428] |
p03073 | u247465867 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['#2019/10/24\nS = list(map(int, list(open(0).read())))\n# print(S)\nprint(S[::2].count(0) + S[1::2].count(1) if S[0]==1 else S[::2].count(1) + S[1::2].count(0)) ', '#2019/10/24\n# S = list(map(int, list(open(0).read())))\nS = list(map(int, input()))\n# print(S)\nprint(S[::2].count(0) + S[1::2].count(1) if S[0]==1 else... | ['Runtime Error', 'Accepted'] | ['s351050051', 's817337248'] | [4656.0, 4256.0] | [32.0, 33.0] | [157, 187] |
p03073 | u248984274 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['s = input()\nn = len(s)\ncount = 0\ncount2 = 0\nprint(s, len(s))\nfor i in range(n):\n if i % 2 == 0:\n x = "0"\n else:\n x = "1"\n if s[i] == x:\n count2 += 1\n #print(i, s[i], x, "OK")\n else:\n count += 1\n #print(i, s[i], x)\nprint(min(count,count2))', 's = in... | ['Wrong Answer', 'Accepted'] | ['s964796753', 's111890335'] | [3316.0, 3188.0] | [52.0, 51.0] | [292, 215] |
p03073 | u255834721 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['li = list(map(input().split()))\nsum = 0;\nfor i in li:\n if(li[i] != li[i + 1]):\n sum += 1\n if((i+1) >= len(li)):\n break;\nprint(sum)\n', "li = list(input())\nsums = 0\nleng = int(len(li))\n\nfor i in range(leng):\n now = i\n print(now)\n if (now + 1) >= leng:\n print(now)\n break\n... | ['Runtime Error', 'Wrong Answer', 'Accepted'] | ['s893137445', 's983662036', 's997907257'] | [3188.0, 4740.0, 3956.0] | [17.0, 143.0, 64.0] | [139, 325, 291] |
p03073 | u259861571 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ["S = list(input())\nn = len(S)\n\ns1 = 0\ns2 = 0\n\nfor i in range(n):\n if i%2 == 0:\n if S[i] == '1':\n s1 += 1\n else:\n s2 += 1\n else:\n if S[i] == '0':\n s2 += 1\n else:\n s1 += 1\nprint(min(s1, s2))", "S = list(input())\nn = len(S)\n\... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s086642828', 's917547230', 's253561168'] | [3956.0, 3956.0, 3956.0] | [49.0, 47.0, 79.0] | [265, 266, 311] |
p03073 | u262801165 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['s = input()\ncount = 0\n\nfor i in range(len(s)):\n if i % 2 == 0:\n if int(s[i]) == "0":\n count += 1\n else:\n if int(s[i]) == "1":\n count += 1\n\nprint(min(count, len(s) - count))\n\n', 's = input()\ncount = 0\n\nfor i in range(len(s)):\n if i % 2 == 0:\n if s[i... | ['Wrong Answer', 'Accepted'] | ['s309807377', 's432456715'] | [3188.0, 3188.0] | [59.0, 49.0] | [216, 206] |
p03073 | u262849744 | 2,000 | 1,048,576 | N tiles are arranged in a row from left to right. The initial color of each tile is represented by a string S of length N. The i-th tile from the left is painted black if the i-th character of S is `0`, and painted white if that character is `1`. You want to repaint some of the tiles black or white, so that any two a... | ['S = input();\n\nS_slice =S[0:2];\nchange =0;\nif S_slice =="000"or S_slice =="111" or S_slice =="110" or S_slice =="001":\n change +=1;\n\nS_list = list(S);\n\nfor i in range(len(S_list)-3):\n if S_list[i+2] == S_list[i+3]:\n S_list[i+3] = str(1-int(S_list[i+2]));\n change +=1;\n\nprint(change);\n... | ['Wrong Answer', 'Accepted'] | ['s780064314', 's324827004'] | [6772.0, 4652.0] | [79.0, 63.0] | [303, 286] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.