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 |
|---|---|---|---|---|---|---|---|---|---|---|
p03773 | u699347638 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['import math\ndef digit(X):\n d = 0\n while X:\n X //= 10\n d += 1\n return d\n\ndef F(A, B):\n return max(digit(A), digit(B))\n\nN = int(input())\n\nmin_F = 20\nmax_div = round(math.sqrt(N))\nfor i in range(1, max_div):\n if N % i == 0:\n f = F(i, N/i)\n if f < min_F:\n ... | ['Runtime Error', 'Accepted'] | ['s672360627', 's089612348'] | [3060.0, 3316.0] | [17.0, 20.0] | [330, 53] |
p03773 | u699522269 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['A,B = map(int,input().split())\nreturn A+B % 24', 'A,B = map(int,input().split())\nprint((A+B) % 24)'] | ['Runtime Error', 'Accepted'] | ['s754744636', 's234389287'] | [8896.0, 9092.0] | [24.0, 24.0] | [46, 48] |
p03773 | u703890795 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['A B = map(int, input().split())\nprint((A+B)%24)\n', 'A B = map(int, input().split())\nprint((A+B)%24)', 'A, B = map(int, input().split())\nprint((A+B)%24)\n'] | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s058863408', 's092626980', 's939113889'] | [2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0] | [48, 47, 49] |
p03773 | u706884679 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['l = input().split()\nA = l[0]\nB = l[1]\nT = A + B\nif T < 24:\n\tprint(T)\nelse:\n\tprint(T-24)', 'l = input().split()\nA = int(l[0])\nB = int(l[1])\n\nT = int(A + B)\nif T < 24:\n\tprint(T)\nelse:\n\tprint(T - 24)'] | ['Runtime Error', 'Accepted'] | ['s743214012', 's122183504'] | [2940.0, 2940.0] | [18.0, 17.0] | [87, 105] |
p03773 | u712768978 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['print((int(input())+int(input()))%24)', 'a, b = map(int, input().split())\nprint((a+b)%24)'] | ['Runtime Error', 'Accepted'] | ['s770164691', 's210986530'] | [2940.0, 2940.0] | [17.0, 17.0] | [37, 48] |
p03773 | u729535891 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['A, B = map(int, input())\nprint((A + B) % 24)', 'A, B = map(int, input().split())\nprint((A + B) % 24)\n'] | ['Runtime Error', 'Accepted'] | ['s977989525', 's431299248'] | [2940.0, 2940.0] | [17.0, 20.0] | [44, 53] |
p03773 | u732844340 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['a = list(map(int, input().split()))\nprint(int((a[0] + a[1]) / 24))', 'a = list(map(int, input().split()))\nprint(int((a[0] + a[1]) % 24))'] | ['Wrong Answer', 'Accepted'] | ['s847443324', 's595272189'] | [2940.0, 2940.0] | [17.0, 17.0] | [66, 66] |
p03773 | u739798900 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['time_input = input()\ntime = time_input.split()\n\nA = time[0]\nB = time[1]\n\nif A + B > 24:\n print(A + B - 24)\nelif A + B == 24:\n print(0)\nelse:\n print(A + B)', 'time_input = input()\ntime = time_input.split()\n\nA = int(time[0])\nB = int(time[1])\n\nif A + B >= 24:\n print(A + B - 24)\n\nelse:\n ... | ['Runtime Error', 'Accepted'] | ['s338185633', 's611386398'] | [2940.0, 2940.0] | [18.0, 17.0] | [163, 144] |
p03773 | u740047492 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['A. B = map(int, input().split())\nif A + B >= 24:\n print((A + B) - 24)\nelse:\n print(A + B)', 'A, B = map(int, input().split())\nif A + B >= 24:\n print(A + B)\nelse:\n print((A + B) - 24)', 'a, b = map(int, input().split())\nA = a+b\nif A > 24:\n print(A-24)\nelif A < 24:\n print(A)\nelif A == 24:\n print("... | ['Runtime Error', 'Wrong Answer', 'Accepted'] | ['s253515597', 's902001650', 's692980198'] | [2940.0, 2940.0, 2940.0] | [17.0, 17.0, 18.0] | [91, 91, 116] |
p03773 | u740767776 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['A, B = int(input().split())\nif A + B > 24:\n print(A + B -24)\nelse:\n print(A + B)', 'A, B = map(int,input().split())\nif A + B >= 24:\n print(A + B -24)\nelse:\n print(A + B)'] | ['Runtime Error', 'Accepted'] | ['s191053638', 's690760820'] | [2940.0, 2940.0] | [18.0, 17.0] | [82, 87] |
p03773 | u748135969 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['a, b = int(map, input().split())\n\nh = a + b\n\nif h < 24:\n print(h)\nelse:\n print(24 - h)', 'a, b = map(int, input().split())\n \nh = a + b\n \nif h < 24:\n print(h)\nelse:\n print(h - 24)'] | ['Runtime Error', 'Accepted'] | ['s882986235', 's290533274'] | [2940.0, 2940.0] | [17.0, 17.0] | [88, 90] |
p03773 | u762540523 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['a,b=map(int, input().split());print((a+b)//24)', 'a,b=map(int, input().split());print((a+b)%24)'] | ['Wrong Answer', 'Accepted'] | ['s627902663', 's591696098'] | [2940.0, 2940.0] | [18.0, 18.0] | [46, 45] |
p03773 | u762603420 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['N, M = list(map(int, input().split()))\n\na = []\nc = []\nfor i in range(0, N + M):\n s = list(map(int, input().split()))\n if i < N:\n a.append(s)\n else:\n c.append(s)\n\nfor i in range(0, N):\n min_idx = 0\n min_dis = 999999999999\n for j in range(0, M):\n dis = abs(a[i][0] ... | ['Runtime Error', 'Accepted'] | ['s309896863', 's354319920'] | [3064.0, 3316.0] | [17.0, 21.0] | [442, 89] |
p03773 | u766407523 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['print(sum(list(map(int, input().split())))//24)', 'print(sum(list(map(int, input().split())))%24)'] | ['Wrong Answer', 'Accepted'] | ['s955622971', 's186971813'] | [2940.0, 2940.0] | [17.0, 17.0] | [47, 46] |
p03773 | u785205215 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['def read_int_list():\n return list(int(i) for i in input().split())\nx,y = read_int_list()\nprint((x+y)%12)', 'def read_int_list():\n return list(int(i) for i in input().split())\n \nx,y = read_int_list()\nprint((x+y)%24)\n'] | ['Wrong Answer', 'Accepted'] | ['s976339469', 's334690638'] | [2940.0, 2940.0] | [17.0, 17.0] | [107, 113] |
p03773 | u786020649 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['a,b=map(int,input())\n\nprint((a+b)%24)', 'a,b=map(int,input().split())\n \nprint((a+b)%24)'] | ['Runtime Error', 'Accepted'] | ['s858452975', 's333480220'] | [9048.0, 9080.0] | [25.0, 26.0] | [37, 46] |
p03773 | u790865353 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['A,B=map(int,input().split())\nprint((a + b) % 24)', 'A,B=map(int,input().split())\nprint((A + B) % 24)'] | ['Runtime Error', 'Accepted'] | ['s636740144', 's758746036'] | [2940.0, 2940.0] | [17.0, 17.0] | [48, 48] |
p03773 | u794543767 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['import sys\na = sys.stdin.readline()\na,b = a.strip().split(" ")\nprint((int(a)-int(b))/24)', 'print(A+B/24)', 'import sys\na = sys.stdin.readline()\na,b = a.strip().split(" ")\nprint((int(a)+int(b))%24)'] | ['Wrong Answer', 'Runtime Error', 'Accepted'] | ['s145740738', 's284989906', 's424620583'] | [2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0] | [88, 13, 88] |
p03773 | u835575472 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['a, b = map(int, input().split)\nprint((a + b) % 24)', 'a, b = map(int, input().split())\nprint((a + b) % 24)\n'] | ['Runtime Error', 'Accepted'] | ['s622866082', 's326744995'] | [9032.0, 9140.0] | [24.0, 25.0] | [50, 53] |
p03773 | u841623074 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['N=int(input())\nn=len(str(N))\nm=(n//2)\ndef wari(x):\n array=[]\n if m==0:\n for j in range(9,0,-1):\n if N%j==0:\n c=max(len(str(N//j)),len(str(j)))\n array.append(c)\n break\n \n for i in range(m+1):\n if i==0:\n for j... | ['Runtime Error', 'Accepted'] | ['s532115101', 's947128859'] | [3064.0, 2940.0] | [18.0, 18.0] | [715, 44] |
p03773 | u850582941 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['A = int(input())\nB = int(input())\n\nans1 = A + B\n\n\nif ans1 >= 24:\n ans2 = ans1 - 24\n print(ans2)\nelse:\n print(ans1)\n \n \n ', 'A,B = map(int,input().split())\n\nans1 = A + B\n\n\nif ans1 >= 24:\n ans2 = ans1 - 24\n print(ans2)\nelse:\n print(ans1)\n \n \n \n'] | ['Runtime Error', 'Accepted'] | ['s856607830', 's399082561'] | [2940.0, 2940.0] | [17.0, 17.0] | [138, 136] |
p03773 | u852790844 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['a, b = map(int, input())\nans = (a+b)%24\nprint(ans)', 'a, b = map(int, input().split())\nans = (a+b)%24\nprint(ans)'] | ['Runtime Error', 'Accepted'] | ['s066780121', 's773589290'] | [2940.0, 2940.0] | [17.0, 17.0] | [50, 58] |
p03773 | u853900545 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['a,b = map(int,input().splilt())\nprint((a+b)//24)', 'a,b = map(int,input().split())\nprint((a+b)%24)\n'] | ['Runtime Error', 'Accepted'] | ['s022608508', 's331004407'] | [2940.0, 2940.0] | [17.0, 17.0] | [48, 47] |
p03773 | u854627522 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['import sys\na, b = sys.stdin.readline().split()\n\nprint((a+b)%24)', 'import sys\na, b = map(int, sys.stdin.readline().split())\n\nprint((a+b)%24)\n'] | ['Runtime Error', 'Accepted'] | ['s700889294', 's773705228'] | [2940.0, 2940.0] | [17.0, 18.0] | [63, 74] |
p03773 | u860002137 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['A, B = map(int, input().split())\nprint((A + B) // 24)', 'A, B = map(int, input().split())\nprint((A + B) % 24)'] | ['Wrong Answer', 'Accepted'] | ['s972143704', 's995565734'] | [2940.0, 2940.0] | [17.0, 17.0] | [53, 52] |
p03773 | u863370423 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['a,b=map(int,input().split())\nif (a>b):\n s=a+b\n s=s%24\nif (b>=a):\n s=a-b\nif (s<=0):\n s=s*-1\n\nprint(s)\n\n', 'a, b=input().split(" ")\na=float(a)\nb=float(b)\ns=a-b\nif( s> 0 and s<=24 ):\n t=b-a\nif(s <=0 ):\n tm=s%24\n t=24+tm\n \nif (s<24 ):\n tm=s%24\n t=24-tm\nprint(\'%d\'%t)... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s391186097', 's910537168', 's624804511'] | [2940.0, 3060.0, 2940.0] | [17.0, 17.0, 17.0] | [114, 177, 71] |
p03773 | u864565901 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['print((int(input())+int(input()))%24)', 'print(sum(map(int,input().split()))%24)'] | ['Runtime Error', 'Accepted'] | ['s839715071', 's212060627'] | [2940.0, 2940.0] | [17.0, 17.0] | [37, 39] |
p03773 | u865413330 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['a, b = map(int, input().split())\nprint(a + b) if a + b > 24 else print(a + b - 24)', 'a, b = map(int, input().split())\nprint(a + b) if a + b < 24 else print(a + b - 24)'] | ['Wrong Answer', 'Accepted'] | ['s382625973', 's912750052'] | [2940.0, 2940.0] | [17.0, 17.0] | [82, 82] |
p03773 | u869519920 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['a, b = map(int, input().split())\nprint((a+b)//24)', 'a, b = map(int, input().split())\nprint((a+b)%24)'] | ['Wrong Answer', 'Accepted'] | ['s809884281', 's526996035'] | [9028.0, 9152.0] | [26.0, 30.0] | [49, 48] |
p03773 | u871596687 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['a,b = map(int,input().split())\n\nif a+b>24\n print(a+b-24)\nelse:\n print(a+b)\n', 'a,b = map(int,input().split())\n\nif a+b>=24:\n print(a+b-24)\nelse:\n print(a+b)\n\n\n'] | ['Runtime Error', 'Accepted'] | ['s077848735', 's131631942'] | [2940.0, 2940.0] | [17.0, 17.0] | [81, 85] |
p03773 | u871841829 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['A\n \nB\n', 'A,B = map(int, input().split())\n\nans = None\n\nif A+B > 23:\n ans = A+B-24\nelse:\n ans = A+B\nprint(ans)\n'] | ['Runtime Error', 'Accepted'] | ['s270739387', 's209468257'] | [2940.0, 2940.0] | [17.0, 17.0] | [6, 102] |
p03773 | u886902015 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['a,b=int(input().split())\nprint((a+b)%24)', 'a,b=map(int,input().split())\nprint((a+b)%24)'] | ['Runtime Error', 'Accepted'] | ['s457471392', 's723914368'] | [8952.0, 9084.0] | [24.0, 28.0] | [40, 44] |
p03773 | u891438775 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['def r_t(n):\n return sum(map(int, n.split()))%24\nr_t(input())', 'def r_t(n):\n return sum(map(int, n.split()))%24\nprint(r_t(input()))'] | ['Wrong Answer', 'Accepted'] | ['s692309802', 's510999845'] | [2940.0, 2940.0] | [17.0, 17.0] | [63, 70] |
p03773 | u895040371 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['a, b =map(in, input().split())\nprint((a+b)%24)', 'a, b = map(int, input().split())\nprint((a + b)%24)'] | ['Runtime Error', 'Accepted'] | ['s041357963', 's737427264'] | [2940.0, 2940.0] | [17.0, 17.0] | [46, 50] |
p03773 | u904804404 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['print((lambda a,b : (a+b)//24)(list(map(int,input().split())) ))', 'print((lambda a : (a[0]+a[1])%24)(list(map(int,input().split())) ))\n'] | ['Runtime Error', 'Accepted'] | ['s016225519', 's533814656'] | [3064.0, 2940.0] | [17.0, 18.0] | [64, 68] |
p03773 | u918009437 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['a,b = map(int,input().split())\n\nprint(a+b-24)', 'a,b = map(int,input().split())\n\nif (a+b>=24):\n print(a+b-24)\nelse:\n print(a+b)\n'] | ['Wrong Answer', 'Accepted'] | ['s399379498', 's934246484'] | [2940.0, 2940.0] | [17.0, 17.0] | [45, 81] |
p03773 | u923659712 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['a.b=map(int,input().split())\nprint((a+b)%24)', 'n,a,b=map(int,input().split())\nv=list(map(int,input().split()))\nv.sort()\nv.reverse()\nave=0\nfor i in range(a):\n ave+=v[i]\n \nprint(ave/a)\n\nl=0\nfor j in range(a,b):\n if v[a-1]==v[j]:\n l+=1\n \np=v.count(v[a-1])\n\nfrom math import factorial\na=factor... | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s148538729', 's773265932', 's367868034'] | [2940.0, 3064.0, 2940.0] | [18.0, 18.0, 17.0] | [44, 301, 45] |
p03773 | u945028875 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['AB = input()\nABL= AB.replace("\\n", " ").split(" ")\n\nprint(ABL)\nA = ABL[0]\nif len(ABL) == 1:\n C = A\nB = ABL[1]\nC = int(A) + int(B )\nif C >= 24:\n C -= 24\nprint(C)\n', 'AB =input()\nif len(AB) <= 2:\n ABL = [AB]\nelse:\n ABL= AB.replace("\\n", " ").split(" ")\n\nprint(ABL)\nA = int(ABL[0])\nif le... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Accepted'] | ['s071264931', 's088821548', 's604745920', 's951004342', 's106834814'] | [2940.0, 3060.0, 3060.0, 2940.0, 2940.0] | [18.0, 17.0, 17.0, 17.0, 17.0] | [167, 227, 217, 78, 222] |
p03773 | u951582245 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['A,B = map(int,input().split())\nprint((A+B)//24)', 'A,B = map(int,input().split())\nprint((A+B)%24)'] | ['Wrong Answer', 'Accepted'] | ['s539464800', 's476915124'] | [2940.0, 2940.0] | [17.0, 17.0] | [47, 46] |
p03773 | u958506960 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['a, b = map(int, input().split())\nprint(a+b//24)', 'a, b = map(int, input().split())\nprint((a+b)%24)'] | ['Wrong Answer', 'Accepted'] | ['s728510632', 's203718524'] | [2940.0, 2940.0] | [17.0, 17.0] | [47, 48] |
p03773 | u960513073 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['a,b = list(map(int, input().split()))\nprint(mod(a+b))', 'a,b = list(map(int, input().split()))\nprint((a+b)%24)'] | ['Runtime Error', 'Accepted'] | ['s542901035', 's051489329'] | [2940.0, 2940.0] | [18.0, 17.0] | [53, 53] |
p03773 | u972892985 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['a, b = map(int,input().split())\nprint((a+b)%12)', 'a, b = map(int,input().split())\nprint((a+b)%24)\n'] | ['Wrong Answer', 'Accepted'] | ['s968663126', 's623636174'] | [2940.0, 2940.0] | [17.0, 17.0] | [47, 48] |
p03773 | u975024434 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['import sys\n\nsys.setrecursionlimit(10000)\n\n\ndef memoize(f):\n cache = {}\n\n def func(*args):\n if args not in cache:\n cache[args] = f(*args)\n return cache[args]\n\n return func\n\n\n@memoize\n\n\n\ndef combi(n, r):\n if r == 0 or n == r:\n return 1\n return combi(n-1, r-1... | ['Runtime Error', 'Accepted'] | ['s639369800', 's795503115'] | [3064.0, 2940.0] | [17.0, 17.0] | [699, 140] |
p03773 | u986269893 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['num=input().split(" ")\na=num[0]\nb=num[1]\nif a+b>=24:\n\tprint(a+b-24)\nelse:\n\tprint(a+b)', 'num=input().split(" ")\na=int(num[0])\nb=int(num[1])\nif a+b>=24:\n\tprint(a+b-24)\nelse:\n\tprint(a+b)'] | ['Runtime Error', 'Accepted'] | ['s974667622', 's050545433'] | [2940.0, 3064.0] | [17.0, 24.0] | [85, 95] |
p03773 | u989008537 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['N, A, B = map(int, input().split())\nL = list(map(int, input().split()))\n\nnum = [0 for x in range(N)]\ntotal = [0 for x in range(N)]\n\nfor i, v in enumerate(L):\n for j in reversed(range(1, i + 1)):\n new_v = total[j - 1] + v\n if(new_v > total[j]):\n total[j] = new_v\n num[j... | ['Runtime Error', 'Accepted'] | ['s897069629', 's555681244'] | [3064.0, 3064.0] | [17.0, 17.0] | [726, 99] |
p03773 | u989326345 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['A,B=map(int,input().split())\nans=(A+B)//24\nprint(ans)\n', 'A,B=map(int,input().split())\nans=(A+B)%24\nprint(ans)\n'] | ['Wrong Answer', 'Accepted'] | ['s180988378', 's584670081'] | [2940.0, 2940.0] | [17.0, 17.0] | [54, 53] |
p03773 | u992910889 | 2,000 | 262,144 | Dolphin loves programming contests. Today, he will take part in a contest in AtCoder. In this country, 24-hour clock is used. For example, 9:00 p.m. is referred to as "21 o'clock". The current time is A o'clock, and a contest will begin in exactly B hours. When will the contest begin? Answer in 24-hour time. | ['A,B=map(str,input().split())\n#print(sorted(B)[0])\nprint((A+B)%24)', 'A,B=map(int,input().split())\n#print(sorted(B)[0])\nprint((A+B)%24)'] | ['Runtime Error', 'Accepted'] | ['s738056989', 's929284073'] | [2940.0, 2940.0] | [17.0, 17.0] | [65, 65] |
p03774 | u013408661 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n,m=map(int,input().split())\nstudent=[]\nman=[]\nfor i in range(n):\n x,y=map(int,input().split())\n student.append([x,y])\nfor i in range(m):\n x,y=map(int,input().split())\n man.append([x,y])\nfor i in student:\n ans=[]\n for j in man:\n ans.append(abs(i[0]-j[0])+abs(i[1]-j[1]))\n print(ans.index(max(ans... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s353260642', 's935910680', 's040988407'] | [3064.0, 3064.0, 3064.0] | [19.0, 19.0, 18.0] | [310, 308, 310] |
p03774 | u016323272 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['N,M = map(int,input().split())\nLs = []\nLp = []\nfor i in range(N):\n a,b = map(int,input().split())\n Ls.append([a,b])\nfor m in range(M):\n c,d = map(int,input().split())\n Lp.append([c,d])\ndis =[]\nfor i in range(N):\n for m in range(M):\n dis.append(abs(Ls[i][0]-Lp[m][0])+abs(Ls[i][1]-Lp[m... | ['Wrong Answer', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted'] | ['s089589617', 's498566642', 's660875506', 's736653594', 's803720486', 's832354212', 's888566176', 's967271503'] | [3064.0, 3064.0, 3064.0, 3064.0, 3064.0, 3064.0, 3064.0, 3064.0] | [21.0, 18.0, 18.0, 17.0, 18.0, 18.0, 17.0, 19.0] | [345, 376, 359, 352, 353, 364, 356, 350] |
p03774 | u020604402 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['students = []\nfor _ in range(N):\n l = list(map(int,input().split()))\n students.append(l)\n\ncheck_points = []\n\nfor _ in range(M):\n l = list(map(int,input().split()))\n check_points.append(l)\n\nminimum_points = 0\n\nfor person in students:\n minimum = 10**10\n for i in range(len(check_points))... | ['Runtime Error', 'Accepted'] | ['s272372766', 's121026074'] | [3064.0, 3064.0] | [18.0, 19.0] | [490, 521] |
p03774 | u023229441 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n,m=map(int,input().split())\nA=[]\nB=[]\nfor i in range(n):\n A.append(list(map(int,input().split())))\nfor i in range(m):\n B.append(list(map(int,input().split())))\n\nfor i in A:\n man=1000000000\n for j in B:\n man=min(man,abs(i[0]-j[0])+abs(i[1]-j[1]))\n print(man)', 'n,m=map(int,input().split())\nA=[]\n... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s015748443', 's372542786', 's410622295'] | [3064.0, 3064.0, 3064.0] | [18.0, 18.0, 18.0] | [266, 359, 362] |
p03774 | u026155812 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['N, M = [int(i) for i in input().split()]\nA = [[int(i) for i in input().split()] for j in range(N)]\nC = [[int(i) for i in input().split()] for j in range(M)]\n\nls1 = []\nfor i in range(N):\n ls2 = []\n for j in range(M):\n ls2.append(abs(A[i][0] - C[j][0]) + abs(A[i][1] - C[j][1]))\n a = min(ls2)\n ... | ['Wrong Answer', 'Runtime Error', 'Accepted'] | ['s623157124', 's965572466', 's617829646'] | [3192.0, 3064.0, 3064.0] | [20.0, 18.0, 19.0] | [362, 386, 364] |
p03774 | u026788530 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['3 4\n10 10\n-10 -10\n3 3\n1 2\n2 3\n3 5\n3 5', 'n,m=[int(_)for _ in input().split()]\n\nab=[[int(_) for _ in input().split()]for i in range(n)]\ncd=[[int(_) for _ in input().split()]for i in range(m)]\n\n\ndef dist(p1,p2):\n return abs(p1[0]-p2[0])+abs(p1[1]-p2[1])\n\nfor i in range(n):\n d=1000000000\n ans=0\n f... | ['Runtime Error', 'Accepted'] | ['s489649830', 's995371193'] | [2940.0, 3064.0] | [17.0, 19.0] | [37, 356] |
p03774 | u027622859 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['N, M = map(int, input().split())\nab = [input().split() for a in range(M)]\ncd = [input().split() for a in range(M)]\n\n\nfor y in range(M):\n min_p = 999\n point = 1\n for x in range(M):\n distance = abs(int(ab[y][0]) - int(cd[x][0])) + abs(int(ab[y][1]) - int(cd[x][1]))\n if min_p == distance... | ['Runtime Error', 'Accepted'] | ['s216354850', 's182256322'] | [3064.0, 3064.0] | [21.0, 19.0] | [430, 465] |
p03774 | u046158516 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n,m=map(int,input().split())\na=[]\nb=[]\nfor i in range(n):\n x,y=map(int,input().split())\n a.append(x,y)\nfor i in range(m):\n x,y=map(int,input().split())\n b.append(x,y)\nfor i in a:\n ans=10**18\n t=0\n for j in b:\n if abs(i[0]-j[0])+abs(i[1]-j[1])<ans:\n t=j+1\n ans=abs(i[0]-j[0])+abs(i[1]... | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s195187021', 's668050145', 's310891934'] | [3064.0, 3064.0, 3064.0] | [17.0, 18.0, 18.0] | [320, 340, 344] |
p03774 | u049595114 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['N, M = list(map(int, input().split()))\nstudents = list()\ncheckpoints = list()\n\nfor i in range(N):\n\tstudents.append(list(map(int, input().split())))\n\nfor i in range(M):\n\tcheckpoints.append(list(map(int, input().split())))\n\nans = [0] * N\n\nfor i in range(N):\n\tmindif = 4 * 10**8 + 1\n\tfor j in range(M):\... | ['Runtime Error', 'Accepted'] | ['s939023944', 's307011484'] | [3064.0, 3064.0] | [19.0, 19.0] | [474, 478] |
p03774 | u055687574 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['N, M = map(int, input().split())\n\nab = [map(int, input().split()) for _ in range(N)]\ncd = [list(map(int, input().split())) for _ in range(M)]\n\nfor n in range(N):\n ans = []\n a, b = ab[n]\n for m in range(M):\n c, d = cd[m]\n distance = abs(a - c) + abs(b - d)\n ans.append(distance)... | ['Wrong Answer', 'Accepted'] | ['s991841641', 's357487728'] | [3064.0, 3064.0] | [18.0, 18.0] | [338, 343] |
p03774 | u059262067 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['A = list(map(int,input().split(" ")))\nH = list()\nC = list()\nresult = list()\nfor i in range(A[0]):\n H.append(list(map(int,input().split(" "))))\nfor i in range(A[1]):\n C.append(list(map(int,input().split(" "))))\n \nfor i in range(A[0]):\n res = 0\n tmp = 99999999\n for ii in range(A[1]):\n ... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s016380179', 's118124368', 's317377202', 's640409607', 's979807803', 's907912924'] | [3064.0, 3064.0, 3064.0, 3064.0, 3064.0, 3064.0] | [17.0, 19.0, 17.0, 19.0, 20.0, 19.0] | [455, 453, 507, 440, 506, 509] |
p03774 | u063073794 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['yandy\nn, m = map(int, input().split())\n\nstudent = []\n\nfor i in range(n):\n a, b = map(int, input().split())\n student.append((a, b))\n\npoint = []\n\nfor j in range(m):\n c, d = map(int, input().split())\n point.append((c, d))\n\nfor a, b in student:\n length = 10 ** 10\n pn = 0\n for j in r... | ['Runtime Error', 'Accepted'] | ['s707128424', 's347007478'] | [3064.0, 3064.0] | [17.0, 18.0] | [452, 315] |
p03774 | u072606168 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ["n,m=map(int,input())\na,b,c,d=[],[],[],[]\nfor i in range(n):\n o = list(map(int, input().split()))\n a.append(o[0])\n b.append(o[1])\nfor i in range(m):\n o = list(map(int, input().split()))\n c.append(o[0])\n d.append(o[1])\ns = []\nfor i in range(n):\n g = float('inf')\n h = 0\n for j in range(m):\n if... | ['Runtime Error', 'Accepted'] | ['s572655960', 's313326771'] | [3064.0, 3064.0] | [18.0, 18.0] | [429, 475] |
p03774 | u072717685 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n, m = map(int,input().split())\nstudents = [None]*n\npoints = [None]*m\nfor i in range(n):\n students[i] = tuple(map(int,input().split()))\nfor i in range(m):\n points[i] = tuple(map(int,input().split()))\n\nans = [None]*n\nfor s in students:\n tmp = [None]*m\n for p in points:\n tmp[p] = abs(students[s][0] -... | ['Runtime Error', 'Accepted'] | ['s825082334', 's060489689'] | [3064.0, 3064.0] | [17.0, 19.0] | [424, 385] |
p03774 | u074220993 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ["N, M = map(int, input().split())\nstudent = [tuple(map(int, input().split())) for _ in range(N)]\ncheckpoint = [tuple(map(int, input().split())) for _ in range(M)]\n\nclosest = {}\nfor s in student:\n min_dist = 'INF'\n ans = 1\n for c in checkpoint:\n dist = abs(s[0]-c[0]) + abs(s[1]-c[1])\n i... | ['Wrong Answer', 'Accepted'] | ['s122120351', 's881294603'] | [9196.0, 9156.0] | [26.0, 28.0] | [470, 427] |
p03774 | u075012704 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['# B-Checkpoints\n\n\nN, M = map(int, input().split()) \nABs = [] \nCDs = [] \n\n\nfor i in range(N):\n ABs.append([int(x) for x in input().split()])\n\n\nfor i in range(N):\n CDs.append([int(x) for x in input().split()])\n\nfor a,b in ABs:\n \n distance = [abs(a-c) + abs(b-d) for c,d in CDs]\n print(di... | ['Runtime Error', 'Accepted'] | ['s175880012', 's543700506'] | [3060.0, 3064.0] | [19.0, 19.0] | [1006, 985] |
p03774 | u078276601 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n,m=map(int,input().split())\nab=[list(map(int, input().split())) for i in range(n)]\ncd=[list(map(int, input().split())) for j in range(m)]\n\nfor i in range(n):\n l=[]\n for j in range(m):\n dist=abs(ab[i][0]-cd[j][0])+abs(ab[i][1]-cd[j][1])\n l.append(dist)\n print(l)\n goal = l.index(min... | ['Wrong Answer', 'Accepted'] | ['s568114372', 's236461835'] | [9172.0, 9000.0] | [32.0, 27.0] | [330, 317] |
p03774 | u088488125 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n,m=map(int, input().split())\na_list=[]\nb_list=[]\nfor i in range(n):\n a,b=map(int, input().split())\n a_list.append(a)\n b_list.append(b)\nc_list=[]\nd_list=[]\nfor i in range(m):\n c,d=map(int, input().split())\n c_list.append(c)\n d_list.append(d)\nfor i in range(n):\n min=0\n min_number=0\n for j in r... | ['Runtime Error', 'Accepted'] | ['s493281029', 's531420634'] | [9148.0, 9160.0] | [24.0, 31.0] | [411, 442] |
p03774 | u094565093 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['N,M=map(int,input().split())\nS=[list(map(int,input().split())) for i in range(N)]\nT=[list(map(int,input().split())) for i in range(M)]\nfor i in range(N):\n x1=S[i][0]\n y1=S[i][1]\n x2=T[0][0]\n y2=T[0][1]\n min=abs(x1-x2)+abs(y1-y2)\n x1=S[i][0]\n y1=S[i][1]\n for j in range(M-1,-1,-1):\n ... | ['Runtime Error', 'Accepted'] | ['s093015656', 's664869268'] | [3064.0, 3064.0] | [18.0, 19.0] | [480, 373] |
p03774 | u099566485 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ["n,m=map(int,input().split())\ns=[]\np=[]\nmd=[[None,float('INF')] for i in range(n)]\nfor i in range(n):\n t1,t2=map(int,input().split())\n s.append([t1,t2])\nfor i in range(m):\n t1,t2=map(int,input().split())\n p.append([t1,t2])\nfor i in range(n):\n for j in range(m):\n if md[i][1]>abs(s[i][0... | ['Wrong Answer', 'Accepted'] | ['s703895374', 's572012056'] | [3064.0, 3064.0] | [19.0, 19.0] | [402, 465] |
p03774 | u103099441 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n, m = map(int, input().split())\ns = []\nd = []\nfor i in range(n):\n x, y = map(int, input().split())\n s.append([x, y])\nfor i in range(m):\n x, y = map(int, input().split())\n d.append([x, y])\nfor i in s:\n a = m\n c = abs(i[0] - x) + abs(i[1] - y)\n for j in range(m):\n c_t = abs(i[0... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s011231796', 's594563399', 's919827927', 's650706556'] | [3064.0, 3064.0, 3064.0, 3064.0] | [18.0, 19.0, 19.0, 18.0] | [418, 434, 418, 438] |
p03774 | u103902792 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ["n,m = map(int,input().split())\nstds = [tuple(map(int,input().split())) for _ in range(n)]\npoints = [tuple(map(int,input().split())) for _ in range(m)]\n\ndef d(s,p):\n return abs(s[0]-p[0]) + abs(s[1] + p[1])\n\nfor std in stds:\n ans = (float('inf'), -1)\n for i, pnt in enumerate(points):\n if d(std,pnt) < a... | ['Wrong Answer', 'Accepted'] | ['s673551883', 's397447137'] | [3064.0, 3064.0] | [18.0, 19.0] | [348, 369] |
p03774 | u105124953 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n, m = map(int,input().split())\nstudent_list = [list(map(int,input().split())) for _ in range(n)]\nprint(student_list)\ncheck_list = [list(map(int,input().split())) for _ in range(m)]\nprint(check_list)\nfor s in student_list:\n tmp = []\n for c in check_list:\n tmp.append(abs(s[0]-c[0]) + abs(s[1]-c[1]... | ['Wrong Answer', 'Accepted'] | ['s930250022', 's268475374'] | [3064.0, 3064.0] | [18.0, 19.0] | [345, 309] |
p03774 | u112902287 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n, m = map(int, input().split())\npos = []\nche = []\nfor i in range(n):\n a,b=map(int,input().split())\n pos.append([a,b])\nfor i in range(m):\n a,b=map(int,input().split())\n che.append([a,b])\n\nfor i in range(n):\n dis = []\n for j in range(m):\n dis.append(abs(pos[i][0]-che[i][0])+abs(po... | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s323614359', 's783946274', 's722895873'] | [3064.0, 3064.0, 3064.0] | [18.0, 19.0, 18.0] | [357, 368, 367] |
p03774 | u121698457 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['N, M = map(int,input().split())\nst = [[] for _ in range(N)]\ncp = [[] for _ in range(M)]\nfor i in range(N):\n a, b = map(int,input().split())\n st[i] = [a, b]\nfor j in range(M):\n c, d = map(int,input().split())\n cp[j] = [c, d]\nfor i in range(N):\n ne = 10**12\n p = 0\n for j in range(M):\n ... | ['Wrong Answer', 'Accepted'] | ['s293827600', 's682052928'] | [3316.0, 3064.0] | [23.0, 19.0] | [474, 438] |
p03774 | u124323472 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n, m = list(map(int, input().split()))\n\na = []\nb = []\n\nfor i in range(n):\n tmp1, tmp2 = list(map(int, input().split()))\n a.append(tmp1)\n b.append(tmp2)\n\nc = []\nd = []\n\nfor i in range(m):\n tmp1, tmp2 = list(map(int, input().split()))\n c.append(tmp1)\n d.append(tmp2)\n\nfor i in range(n... | ['Runtime Error', 'Accepted'] | ['s790416813', 's665554097'] | [3064.0, 3064.0] | [18.0, 19.0] | [513, 513] |
p03774 | u131264627 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n, m = map(int, input().split())\nab = [list(map(int, input().split())) for _ in range(n)]\ncd = [list(map(int, input().split())) for _ in range(m)]\nprint(ab)\nprint(cd)\nfor i in range(n):\n seq_min = 1e9\n ans = -1\n for j in range(m):\n seq = abs(ab[i][0] - cd[j][0]) + abs(ab[i][1] - cd[j][1])\n ... | ['Wrong Answer', 'Accepted'] | ['s261599617', 's954723812'] | [3064.0, 3064.0] | [19.0, 19.0] | [396, 377] |
p03774 | u136395536 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['N,M = (int(i) for i in input().split())\n\n\nstudent = []\nfor i in range(N):\n a,b = (int(i) for i in input().split())\n student.append([a,b])\n\npoint = []\nfor j in range(M):\n c,d = (int(i) for i in input().split())\n point.append([c,d])\n\nminimum = N*[""]\nnumber = N*[0]\n\n\n\nfor i in range(N):\n ... | ['Wrong Answer', 'Runtime Error', 'Wrong Answer', 'Accepted'] | ['s386724235', 's443443502', 's645268043', 's069057253'] | [3064.0, 3064.0, 4340.0, 3064.0] | [20.0, 18.0, 36.0, 19.0] | [631, 648, 1016, 575] |
p03774 | u137228327 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['N,M = map(int,input().split())\nstudent = [list(map(int,input().split())) for _ in range(N)]\ncpoint = [list(map(int,input().split())) for _ in range(M)]\nfor i in range(N):\n mannmn = 10**8\n for j in range(M):\n mann = abs(student[i][0] - cpoint[j][0])+abs(student[i][1] - cpoint[j][1])\n if mann... | ['Runtime Error', 'Accepted'] | ['s580550393', 's126387353'] | [9132.0, 9044.0] | [27.0, 28.0] | [385, 412] |
p03774 | u143903328 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['m,n = map(int,input().split())\nstudent = []\ncheckpoint = []\nfor i in range(n):\n student.append(list(map(int,input().split())))\nfor i in range(m):\n checkpoint.append(list(map(int,input().split())))\n\nfor i in range(m):\n ans = 0 \n tmp = 10000000000000\n for j in range(m):\n if tmp < abs(s... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted'] | ['s321228532', 's489182019', 's544772130', 's576559856', 's428478183'] | [3064.0, 3064.0, 3064.0, 3064.0, 3064.0] | [19.0, 18.0, 19.0, 18.0, 19.0] | [567, 563, 567, 565, 580] |
p03774 | u146575240 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['# B - Checkpoints\nN, M = list(map(int, input().split()))\nP = [list(map(int, input().split())) for i in range(N)]\nC = [list(map(int, input().split())) for i in range(M)]\n\nans = [1]*N\nfor i in range(N): \n D = [10 ** 10] * M\n for j in range(M): \n D[j] = abs(P[i][0]-C[j][0]) + abs(P[i][1]-C[j][1])\n... | ['Wrong Answer', 'Accepted'] | ['s221703967', 's505037042'] | [3064.0, 3064.0] | [22.0, 19.0] | [546, 522] |
p03774 | u163320134 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n,m=map(int,input().split())\npos1=[list(map(int,input().split())) for _ in range(n)]\npos2=[list(map(int,input().split())) for _ in range(m)]\nans=[0]*n\nfor i in range(n):\n lim=10**9\n for j in range(m):\n tmp=abs(pos1[i][0]-pos2[i][0])+abs(pos1[i][1]-pos2[i][1])\n if tmp<lim:\n tmp=lim\n ans[i]=... | ['Runtime Error', 'Accepted'] | ['s087257527', 's310514021'] | [3064.0, 3064.0] | [19.0, 19.0] | [344, 346] |
p03774 | u166696759 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n, m = map(int, input().split())\nA = [(a, b) for a, b in map(int, input().split())]\nC = [(c, d) for c, d in map(int, input().split())]\nfor i in range(n):\n res = 0\n ans = 1 << 20\n for j in range(m):\n tmp = abs(A[i][0] - C[j][0]) + abs(A[i][1] - C[j][1]) )\n if tmp < ans:\n\t ans = tmp\n res = j\n... | ['Runtime Error', 'Accepted'] | ['s697547736', 's409364684'] | [3060.0, 3064.0] | [18.0, 19.0] | [317, 375] |
p03774 | u168416324 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n,m=map(int,input().split())\nst=[]\nch=[]\ndef mht(ax,ay,bx,by):\n return abs(ax-bx)+abs(ay-by)\n\nfor i in range(n):\n st.append(list(map(int,input().split())))\nfor i in range(m):\n ch.append(list(map(int,input().split())))\n \nfor i in st:\n ax=i[0]\n ay=i[1]\n mn=100000000\n for (j,k) in zip(ch,range(len... | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s449785097', 's925381918', 's445735144'] | [9064.0, 9212.0, 9220.0] | [22.0, 25.0, 27.0] | [408, 401, 411] |
p03774 | u185896732 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['import sys\ninput=sys.stdin.readline\n\nn,m=map(int,input().split())\ng=[list(map(int,input().split())) for _ in range(n)]\nc=[list(map(int,input().split())) for _ in range(m)]\n\nfor i in g:\n a,b=i[0],i[1]\n dis=10**10\n ind=1\n for j in range(m):\n x,y=c[j][0],c[j][1]\n now=abs(a-x)+abs(b... | ['Runtime Error', 'Accepted'] | ['s509686081', 's475942861'] | [3064.0, 3064.0] | [17.0, 19.0] | [766, 383] |
p03774 | u209619667 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['a,b = map(int,input().split())\nS = [list(map(int,input().split())) for i in range(a)]\nCP = [list(map(int,input().split())) for i in range(b)]\nfor s in S:\n count = 0\n ab = 10**8\n p = 10**8\n for cp in CP:\n total = abs(s[0]-cp[0]) + abs(s[1]-cp[1])\n count +=1\n print(cp)\n if ab > total:\n ... | ['Wrong Answer', 'Accepted'] | ['s498916807', 's624127308'] | [3188.0, 3064.0] | [21.0, 19.0] | [350, 350] |
p03774 | u220345792 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['N, M = map(int, input().split())\nstu = []\nche = []\nfor i in range(N):\n stu.append(list(map(int, input().split())))\nfor i in range(M):\n che.append(list(map(int, input().split())))\n \nfor i in stu:\n x, y = i[0], i[1]\n ans = 0\n tmp = 99999999999999\n for j in che:\n if abs(x-j[0])+abs(y-j[1]) < tmp:\... | ['Runtime Error', 'Accepted'] | ['s536440897', 's062330206'] | [3064.0, 3064.0] | [18.0, 18.0] | [371, 391] |
p03774 | u225388820 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n,m=map(int,input().split())\np=[tuple(map(int,input().split())) for i in range(n)]\nfor i in range(m):\n c,d=map(int,input().split())\n ans=10**10\n for j,k in p:\n ans=min(ans,abs(c-j)+abs(d-k))\n print(ans)', 'n,m=map(int,input().split())\nnow=[tuple(map(int,input().split())) for i in range(n)]\np=[tuple(ma... | ['Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Accepted'] | ['s029950522', 's107506721', 's680962023', 's923658512', 's062957573'] | [3060.0, 3188.0, 3060.0, 3060.0, 3064.0] | [18.0, 19.0, 19.0, 19.0, 18.0] | [209, 240, 240, 232, 337] |
p03774 | u239375815 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n, m = map(int, input().split())\n\na = [[0, 0] for i in range(n)]\n\nc = [[0, 0] for i in range(m)]\n\nfor i in range(n):\n a[i][0], a[i][1] = map(int, input().split())\n\nfor i in range(m):\n c[i][0], c[i][1] = map(int, input().split())\n\nindex = 0\n\nprint(a,c)\n\nfor i in range(n):\n for j in range(m):\... | ['Wrong Answer', 'Accepted'] | ['s387277809', 's838077062'] | [3064.0, 3064.0] | [19.0, 19.0] | [530, 520] |
p03774 | u248670337 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['3 4\n10 10\n-10 -10\n3 3\n1 2\n2 3\n3 5\n3 5', 'n,m=map(int,input().split())\nA = [list(map(int,input().split())) for _ in range(n)]\nC = [list(map(int,input().split())) for _ in range(m)]\nfor a,b in A:\n l=[abs(a-c)+abs(b-d) for c,d in C]\n print(l.index(min(l))+1)'] | ['Runtime Error', 'Accepted'] | ['s514986708', 's290325687'] | [2940.0, 3060.0] | [17.0, 18.0] | [37, 216] |
p03774 | u252964975 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['def distance(a,b,c,d):\n return abs(a-c)+abs(b-d)\n\nN,M=map(int, input().split())\nAlist = []\nBlist = []\nfor i in range(N):\n a,b=map(int, input().split())\n Alist.append(a)\n Blist.append(b)\nClist = []\nDlist = []\nfor i in range(M):\n c,d=map(int, input().split())\n Clist.append(c)\n Dlist.append(d)\n\nf... | ['Runtime Error', 'Accepted'] | ['s701852859', 's568278779'] | [3064.0, 3064.0] | [18.0, 19.0] | [506, 565] |
p03774 | u257332942 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['a, b, c, d = [0] * n, [0] * n, [0] * m, [0] * m\nfor i in range(n):\n a[i], b[i] = map(int, input().split())\nfor i in range(m):\n c[i], d[i] = map(int, input().split())\n\nfor i in range(n):\n min_dist, min_c = abs(a[0]-c[0]) + abs(b[0]-d[0]), 0\n for j in range(m):\n dist = abs(a[i]-c[j]) + abs(b... | ['Runtime Error', 'Accepted'] | ['s449214456', 's131452071'] | [8812.0, 9072.0] | [26.0, 27.0] | [415, 423] |
p03774 | u281610856 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ["\nC = []\nD = []\nfor i in range(n):\n a, b = map(int, input().split())\n A.append(a)\n B.append(b)\nfor j in range(m):\n c, d = map(int, input().split())\n C.append(c)\n D.append(d)\nfor i in range(n):\n v_min = float('inf')\n for j in range(m):\n v = abs(A[i] - C[j]) + abs(B[i] - D[j]... | ['Runtime Error', 'Accepted'] | ['s606868179', 's522437930'] | [3064.0, 3064.0] | [17.0, 18.0] | [388, 434] |
p03774 | u285443936 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['N, M = map(int, input().split())\na, b, c, d = [],[],[],[]\n\nfor i in range(N):\n ai, bi = map(int, input().split())\n a.append(ai)\n b.append(bi)\n# print(a, b)\nfor j in range(M):\n cj, dj = map(int, input().split())\n c.append(cj)\n d.append(dj)\n \n#print(a,b,c,d)\n \nfor i in range(N):\n dist, min_dis... | ['Runtime Error', 'Accepted'] | ['s413933182', 's483811195'] | [3064.0, 3064.0] | [18.0, 18.0] | [690, 692] |
p03774 | u288430479 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n,m = map(int,input().split())\nl_n =list(list(map(int,input().split())) for i in range(n))\nl_m =list(list(map(int,input().split())) for i in range(m))\nq = 1000000\nfor i in range(n):\n for t in range(m):\n a,b = l_n[i]\n c,d = l_m[t]\n v= abs(a-c)+abs(b-d)\n if v<=q:\n q = v\n z = t\n print... | ['Runtime Error', 'Accepted'] | ['s507620054', 's585506146'] | [3064.0, 3064.0] | [18.0, 19.0] | [329, 310] |
p03774 | u290187182 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ["\nif __name__ == '__main__':\n a, b = map(int, input().split())\n lista=[]\n for i in range(a):\n c = [int(i) for i in input().split()]\n lista.append(c)\n\n listb=[]\n for i in range(b):\n c = [int(i) for i in input().split()]\n listb.append(c)\n\n listc =[]\n\n for i... | ['Wrong Answer', 'Accepted'] | ['s893818671', 's566229523'] | [3064.0, 3064.0] | [18.0, 19.0] | [600, 607] |
p03774 | u306412379 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n, m = map(int, input().split())\nstudents = [list(map(int, input().split())) for i in range(n)]\n\ntargets = [list(map(int, input().split())) for i in range(m)]\nx = 0\nsnumber = [(0, x)] * n\n \ndef md(s, t):\n d = abs(s[0] - t[0]) + abs(s[1] - t[1])\n return d\n\nfor i in range(n):\n x = 2 * 10 ** 8\n for j i... | ['Wrong Answer', 'Accepted'] | ['s489240723', 's031513713'] | [9152.0, 9244.0] | [27.0, 28.0] | [508, 507] |
p03774 | u322185540 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n,m = map(int,input().split())\nx = [0]*n\ny = [0]*n\nmx = [0]*m\nmy = [0]*m\nfor i in range(n):\n x[i],y[i] = map(int,input().split())\nfor j in range(m):\n mx[j],my[j] = map(int,input().split())\nans = [0]*n\nfor k in range(n):\n dis = 0\n cnt = 1\n for l in range(n):\n if abs(x[k]-xs[l])+abs(... | ['Runtime Error', 'Accepted'] | ['s296266805', 's712064494'] | [3064.0, 3064.0] | [18.0, 19.0] | [438, 546] |
p03774 | u343437894 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n, m = map(int, input().split(" "))\n\ndef abs(n):\n return n if n>0 else -n\n\n\nfor i in range(1, n+1):\n ab = list(map(int, input().split(" ")))\nfor j in range(1, m+1):\n cd = list(map(int, input().split(" ")))\n\nfor i in range(0, n):\n delta = 999999999999\n ans=0\n for j in range(0, m):\n ... | ['Runtime Error', 'Wrong Answer', 'Accepted'] | ['s306293552', 's896935662', 's065337278'] | [3064.0, 3064.0, 3064.0] | [18.0, 21.0, 21.0] | [456, 464, 464] |
p03774 | u350093546 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n,m=map(int,input().split())\na=[list(map(int,input().split())) for i in range(n)]\nb=[list(map(int,input().split())) for i in range(m)]\nfor i in a:\n cnt=2*(10**16)\n ans=0\n for j in range(len(b)):\n if abs(i[0]*b[j][0])+ abs(i[1]*b[j][1])<cnt:\n cnt=abs(i[0]*b[j][0])+ abs(i[1]*b[j][1])\n ans=j+1\n... | ['Wrong Answer', 'Accepted'] | ['s770963443', 's417999249'] | [9108.0, 9148.0] | [28.0, 27.0] | [320, 321] |
p03774 | u362560965 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['N,M = map(int,input().split())\n\na = [0 for i in range(N)]\nb = [0 for i in range(N)]\nc = [0 for i in range(M)]\nd = [0 for i in range(M)]\n\nfor i in range(N):\n a[i],b[i] = map(int,input().split())\n\nfor i in range(M):\n c[i],d[i] = map(int,input().split())\n\nfor i in range(N):\n for j in range(M):\n ... | ['Runtime Error', 'Accepted'] | ['s963777468', 's783190023'] | [3064.0, 3064.0] | [19.0, 19.0] | [423, 424] |
p03774 | u364741711 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n,m=map(int,input().split())\n\nli=[list(map(int,input().split())) for i in range(n)]\nlj=[list(map(int,input().split())) for i in range(m)]\n\nfor i in range(n):\n li_distance=[abs(lj[j][0]-li[i][0])+abs(lj[j][1]-li[i][1]) for j in range(m)]\n print(li_distance.index(min(li_distance)+1))\n ', 'n,m=map(int,i... | ['Runtime Error', 'Accepted'] | ['s862703145', 's310171085'] | [3060.0, 3060.0] | [19.0, 19.0] | [293, 293] |
p03774 | u366644013 | 2,000 | 262,144 | There are N students and M checkpoints on the xy-plane. The coordinates of the i-th student (1 \leq i \leq N) is (a_i,b_i), and the coordinates of the checkpoint numbered j (1 \leq j \leq M) is (c_j,d_j). When the teacher gives a signal, each student has to go to the nearest checkpoint measured in _Manhattan distan... | ['n, m = map(int, input().split())\ns = [list(map(int, input().split())) for _ in range(n)]\np = [list(map(int, input().split())) for _ in range(m)]\nfor i in range(n):\n mindis = 10 ** 9\n for j in range(m):\n dis = abs(s[i][0] - p[j][0]) + abs(s[i][1] - p[j][1])\n if mindis > dis:\n p =... | ['Runtime Error', 'Accepted'] | ['s028509077', 's440534970'] | [3064.0, 3064.0] | [18.0, 19.0] | [352, 360] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.