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 |
|---|---|---|---|---|---|---|---|---|---|---|
p02772 | u921927295 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['N = int(input())\nnums = [int(e) for e in input().split()]\nfor i in range(N):\n if nums[i]%2 == 1:\n pass\n else:\n if nums[i]%3 == 0 or nums[i]%3 == 0:\n pass\n else:\n print("DENIED")\n break\n if i == N-1:\n print("APPROVED")\n else:\n ... | ['Wrong Answer', 'Accepted'] | ['s747218129', 's097530515'] | [2940.0, 2940.0] | [17.0, 17.0] | [315, 315] |
p02772 | u922487073 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['N = int(input())\nA_list = list(map(int, input().split()))\n\nf = True\nfor a in A_list:\n if a % 2 == 1:\n continue\n elif a % 3 == 0 or a % 5 == 0:\n continue\n \nif f:\n print("ACCEPTED")\nelse:\n print("DENIED")', 'N = int(input())\nA_list = list(map(int, input().split()))\n \nf = True\nfor a in A_li... | ['Wrong Answer', 'Accepted'] | ['s790113577', 's928033741'] | [3060.0, 3060.0] | [17.0, 17.0] | [215, 238] |
p02772 | u923270446 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['N = int(input())\nA = list(map(int,input().split()))\nfor i in A:\n if i % 2 == 0:\n if i % 3 == 0 or i % 5 == 0:\n print("APPROVED")\n else:\n print("DENIED")\n break\n ', 'N = int(input())\nnumbers = list(map(int, input().split()))\nfor number in nunbers:\n if number % 2 == 0:\n if nu... | ['Wrong Answer', 'Runtime Error', 'Accepted'] | ['s461647585', 's513525433', 's953027313'] | [2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0] | [188, 205, 212] |
p02772 | u925712873 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['n = int(input())\na = list(map(int, input().split()))\n\nfor i in a:\n if i%2 == 0:\n if i%3 and i%5:\n print("DENID")\n exit()\nprint("APPRIVED")', 'n = int(input())\na = list(map(int, input().split()))\n\nfor i in a:\n if i%2 == 0:\n if i%3 and i%5:\n print("DENI... | ['Wrong Answer', 'Accepted'] | ['s101674586', 's920335841'] | [2940.0, 2940.0] | [20.0, 17.0] | [170, 171] |
p02772 | u927534107 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['n=int(input())\nl=list(map(int,input().split()))\nfor i in l:\n if i%2==0 and i%3!=0 and i%5==0:\n print("DENIED")\n exit()\nprint("APPROVED")', 'n=int(input())\nl=list(map(int,input().split()))\nfor i in l:\n if i%2==0 and i%3!=0 or i%5==0:\n print("DENIED")\n exit()\nprint("APPROVE... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s747275666', 's952346506', 's343573556'] | [2940.0, 2940.0, 2940.0] | [17.0, 17.0, 18.0] | [153, 152, 153] |
p02772 | u927807968 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['number = str(input())\nlist = list(map(int, input().split())\nfor i in list:\n\tif i%2==0:\n\t\tif i%3==0 or i%5==0:\n print("APPROVED")\n else:\n print("DENIED")', 'number = input()\nlist1 = list(map(int, input().split()))\nhan = 0\ncount = 0\nfor i in range(0, len(list1)):\n if list1... | ['Runtime Error', 'Accepted'] | ['s873870582', 's047070825'] | [2940.0, 3060.0] | [17.0, 17.0] | [181, 281] |
p02772 | u928480992 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['import sys\nn = int(input())\na = list(map(int, input().split()))\n\nfor i in range(n):\n if a[i] % 2 == 0:\n if a[i] % 3 or a[i] % 5 != 0:\n print("DENIED")\n sys.exit()\n\nprint("APPROVED")\n\n', 'import sys\nn = int(input())\na = list(map(int, input().split()))\n\nfor i in range(n):... | ['Wrong Answer', 'Accepted'] | ['s363995973', 's334922836'] | [2940.0, 2940.0] | [19.0, 18.0] | [215, 216] |
p02772 | u929217794 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['# Papers, Please\n\nN = int(input())\nA = list(map(int, input().split()))\n\nfor Ai in A:\n if Ai % 2 == 1:\n continue\n else:\n if Ai % 3 != 0 and Ai % 5 != 0:\n print("DENIED")\n exit()\n\nprint("AOOROVED")', '# Papers, Please\n\nN = int(input())\nA = list(map(int, input().split()))\n\nfor Ai in A... | ['Wrong Answer', 'Accepted'] | ['s652654319', 's324346792'] | [8932.0, 8900.0] | [28.0, 30.0] | [213, 213] |
p02772 | u935642171 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ["n = int(input())\na = list(int(x) for x in input().split() if int(x)%2==0)\nok = True\nfor i in a:\n if i%3==0 or i%5==0:\n print('DENIED')\n ok = False\n break\nif ok:\n print('APPROVED')", "n = int(input())\na = list(int(x) for x in input().split() if int(x)%2==0)\nok = True\nfor i in a:\n if i%3!=0 and... | ['Wrong Answer', 'Accepted'] | ['s436916179', 's996221623'] | [9080.0, 9120.0] | [27.0, 24.0] | [190, 191] |
p02772 | u935840914 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['n = int(input())\na = list(map(int, input().split()))\nflg = True\nfor i in range(n):\n if a[i] % 2 == 0:\n if a[i] % 3 == 0 or a[i] % 5 == 0:\n pass\n else:\n flg = False\n break\n\nif flg:\n print("APPROVED")\nelse:\n print("DENIED")\n\n', 'n = int(input())\na = list(map(... | ['Wrong Answer', 'Runtime Error', 'Accepted'] | ['s904757106', 's933092625', 's967001051'] | [2940.0, 2940.0, 3060.0] | [17.0, 18.0, 18.0] | [267, 193, 278] |
p02772 | u938892722 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['N = int(input())\n\nA = list(map(int, input().split()))\n\nn=0\n\nfor i in range(N):\n a=A[i]\n if a%2==0 and (a%3!=0 or a%5!=0):\n n+=1\n\nif n==0:\n print("APPROVED")\nelse:\n print("DENIED")', 'N = int(input())\n\nA = list(map(int, input().split()))\n\nfor i in range(N):\n a=A[i]\n if a%2=... | ['Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Wrong Answer', 'Accepted'] | ['s230757763', 's430697551', 's721724357', 's867062702', 's878570329'] | [3060.0, 2940.0, 3060.0, 2940.0, 3060.0] | [17.0, 17.0, 19.0, 17.0, 17.0] | [198, 179, 172, 180, 209] |
p02772 | u939585142 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['N = int(input())\nA = list(map(int,input().split()))\nli = []\nans = "APPROVED"\n\nfor i in range(N):\n if A[i] % 2 == 0:\n li.append(A[i])\n\nfor i in li:\n if i % 5 == 0 or i % 3 == 0:\n ans = "APPROVED"\n else:\n ans = "DENIED"\n break', 'N = int(input())\nA = list(map(int,input().split()))\nli = []... | ['Wrong Answer', 'Accepted'] | ['s441350447', 's898089843'] | [3060.0, 3060.0] | [17.0, 17.0] | [239, 250] |
p02772 | u945359338 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['n = int(input())\nlist = [int(x) for x in input().split(" ")]\nresult = \'APPROVED\'\nfor i in range(len(list)):\n if list[i]%2 == 0:\n if list[i]%3!=0 AND list[i]%5!=0:\n result = \'DENIED\'\n break\nprint(result)', 'n = int(input())\nlist = [int(x) for x in input().split(" ")]\nresul... | ['Runtime Error', 'Accepted'] | ['s855679611', 's979466154'] | [3064.0, 3060.0] | [17.0, 17.0] | [234, 238] |
p02772 | u947797537 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ["N = int(input())\nlst = input().split(' ')\ngood = False\nfor v in lst:\n if int(v) % 2 != 0:\n continue\n elif int(v) % 3 != 0 and int(v) % 5 != 0:\n print('DENIED')\n break\n else:\n good = True\nif good:\n print('APPROVE')", "N = int(input())\nlst = input().split(' ')\nfor v in lst:\n good = False... | ['Wrong Answer', 'Accepted'] | ['s513765524', 's254600524'] | [3060.0, 3060.0] | [18.0, 23.0] | [229, 235] |
p02772 | u952708174 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ["N = int(input())\nA = [int(i) for i in input().split()]\nprint('APPROVED' if all([a % 6 == 0 or a % 10 == 0 for a in A]) else 'DENIED')", "N = int(input())\nA = [int(i) for i in input().split()]\nconditions = [(a % 3 == 0 or a % 5 == 0) for a in A if a % 2 == 0]\nprint('APPROVED' if all(conditions) else 'DENIED')"] | ['Wrong Answer', 'Accepted'] | ['s793451604', 's386044512'] | [2940.0, 3060.0] | [18.0, 17.0] | [133, 172] |
p02772 | u957222656 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['\nnum = input()\na = input().split()\nflag = 0\nfor item in a:\n if item%2==0:\n if item%3==0 or item%5==0:\n pass\n else:\n flag=1\n\nif flag==0:\n print("APPROVED")\nelse:\n print("DENIED")', '\nnum = input()\na = input().split()\nflag = 0\nfor item in a:\n item=int(i... | ['Runtime Error', 'Accepted'] | ['s747271186', 's554489487'] | [2940.0, 2940.0] | [17.0, 17.0] | [222, 241] |
p02772 | u957872856 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['N = int(input())\nA = [int(i) for i in input().split()]\nans = True\nfor a in A:\n if a%2==0:\n if a%3!=0 or a%5!=0:\n ans = False\nif ans:\n print("APPROVED")\nelse:\n print("DENIED")\n ', 'N = int(input())\nA = [int(i) for i in input().split()]\nans = True\nfor a in A:\n if a%2==0:\n if a%3!=0 a... | ['Wrong Answer', 'Accepted'] | ['s713438859', 's042796942'] | [2940.0, 3064.0] | [17.0, 17.0] | [192, 186] |
p02772 | u957957759 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ["n=int(input())\na=list(map(int,input().split()))\nx=0\nfor i in range(n):\n if a[i]%2==0:\n if a[i]%3!=0 and a[i]%3!=0:\n x=1\n break\nif x==1:\n print('DENIED')\nelse:\n print('APPROVED')\n ", "n=int(input())\na=list(map(int,input().split()))\nx=0\nfor i in range(n):\n ... | ['Wrong Answer', 'Accepted'] | ['s306330843', 's355879857'] | [2940.0, 2940.0] | [18.0, 17.0] | [224, 224] |
p02772 | u958207414 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['N = input()\n_list = input().split(" ")\n_list = [int(a) for a in _list]\naspect = [a for a in _list if a % 2==0]\nans = []\nfor a in even:\n if a % 3 == 0 or a % 5 == 0:\n ans.append(True)\nif len(aspect) ==len(ans):\n print("APPROVED")\nelse:\n print("DENIED")', 'N = input()\n_list = input().split("... | ['Runtime Error', 'Accepted'] | ['s578821479', 's414621993'] | [3064.0, 3188.0] | [18.0, 18.0] | [267, 269] |
p02772 | u960250266 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['N = input()\nA = [x for x in input().split()]\nfive = False\nthree = False\nfor x in range(A):\n if(x%5==0):\n five = True\n elif(x%3==0):\n three = True\n \nif(five.equals(True) and three.equals(True)):\n print("APPROVED)\nelse:\n print("DENIED")\n \n', 'N = input()\nA = [x for x in input().split()]\... | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s369034928', 's995410178', 's775685568'] | [2940.0, 2940.0, 3064.0] | [17.0, 17.0, 18.0] | [253, 252, 273] |
p02772 | u961945062 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['N = int(input())\nA = list(map(int, input().split()))\n\nj = True\nfor i in range(N):\n if A[i] % 2 == 0:\n if A[i] %3 == 0 or A[i] % 5 ==0:\n pass\n else:\n j = False\n exit()\n \nif j == Ture:\n print("APPROVED")\nelse:\n print("DENIED") ', 'N = int... | ['Runtime Error', 'Accepted'] | ['s663862316', 's025563085'] | [3060.0, 3060.0] | [17.0, 17.0] | [292, 255] |
p02772 | u964521959 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['\nN = int(input())\n\n\ninput_list = input().split( )\n\nfor i in range(N):\n if(input_list[i]%2==0):\n if((input_list[i]%3==0)or(input_list[i]%5==0)):\n counter = counter + 1\nif(counter == N):\n print("APPROVED")\nelse:\n print("DENIED")', '\nN = int(input())\n\n\ninput_list = input().split( )\n\ncounter... | ['Runtime Error', 'Accepted'] | ['s933821067', 's190015483'] | [3060.0, 3060.0] | [17.0, 17.0] | [269, 333] |
p02772 | u967843578 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['\n\n\n#include <array>\n#include <set>\n#include <cmath>\n#include <string>\n#include <sstream>\n\n#include <list>\n#include <stack>\n\n#include <algorithm> \n#include <numeric> \n#include <functional>\n\n#include <bitset>\n#include <cctype> \n#include <iomanip> \n#include <limits> \n\n// std::numeric_limits<int>:... | ['Runtime Error', 'Accepted'] | ['s497691451', 's332890628'] | [2940.0, 12508.0] | [18.0, 148.0] | [1430, 254] |
p02772 | u970497613 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['N = int(input())\nlist = input().split()\nfor i in range(N):\n on = 0\n k = int(list[i])\n if k % 2 == 0:\n if k % 3 == 0 or k % 5 == 0:\n on = 1 \n else:\n print("DENIED")\n break\n if i == N-1:\n if on == 1:\n \t print("APPROVED")\n else:\n \t print("DENIED")', 'N = int(input())\... | ['Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s272728328', 's318450154', 's486036738', 's607180912', 's648785810', 's532607769'] | [3060.0, 3060.0, 3060.0, 3064.0, 3060.0, 3060.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 17.0] | [280, 281, 229, 292, 231, 228] |
p02772 | u970809473 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ["li = list(map(int,input().split()))\nerror = 0\nfor i in range(li[0]):\n if i == 1:\n else:\n if li[i]%2 == 0:\n if li[i]%3 == 0 or li[i]%5 ==0:\n else:\n error = 1:\n else:\nif error:\n print('DENIED')\nelse:\n print('APPROVED')", "n = int(input())\nli = list(map(int,input().split()))\nerr... | ['Runtime Error', 'Accepted'] | ['s576188735', 's480542192'] | [2940.0, 3060.0] | [17.0, 17.0] | [243, 245] |
p02772 | u971096161 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ["N = int(input())\nA = input().split()\nA = [int(a) for a in A]\n\nans = 'APPROVED'\nfor a in A:\n if a % 2 ==0:\n if a % 3 != 0 or a % 5 != 0:\n ans = 'DENIED'\n break\n \nprint(ans)\n", "N = int(input())\nA = input().split()\nA = [int(a) for a in A]\n\nans = 'APPROVED'\nfor a in A:\n if a % 2 ==0... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s632212907', 's657847529', 's185059301'] | [2940.0, 3060.0, 3060.0] | [18.0, 17.0, 17.0] | [191, 178, 208] |
p02772 | u977141657 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['import numpy as np\nn = int(input())\na = list(map(int, input().split()))\na = np.array(a)\na = a[a%2==0]\n\nfor i in range(n):\n if a[i]%3 != 0 and a[i]%5 != 0:\n return print("APPROVED")\n\nreturn print("DENIED")', 'import numpy as np\nimport sys\n\nn = int(input())\na = list(map(int, input().split()))\na... | ['Runtime Error', 'Accepted'] | ['s792935799', 's603231793'] | [3060.0, 12504.0] | [17.0, 149.0] | [214, 233] |
p02772 | u981864683 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['a = input()\nb = list(map(int,input().split()))\n\nfor i in b:\n if i % 2 == 0:\n if i % 3 == 0 or i % 5 == 0:\n print("APPROVED")\n else:\n print("DENIED")\n else:\n print("DENIED")\n \n\n\n', 'a = input()\nb = list(map(int,input().split()))\n \nlistdir = []\nfor i in b:\n if i % 2 == 0:\n ... | ['Wrong Answer', 'Accepted'] | ['s921031774', 's348621822'] | [2940.0, 3060.0] | [17.0, 19.0] | [201, 216] |
p02772 | u982749462 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ["n=int(input())\na = list(map(int, input().split()))\nfor i in a:\n if a % 2=0:\n if a%3=0 or a%5=0:\n print('APPROVED')\n exit()\nprint('DENIED')", "n=int(input())\na = list(map(int, input().split()))\nfor i in a:\n if i % 2==0:\n if i % 3 == 0 or i % 5 ==0:\n continue\n else:\n print('... | ['Runtime Error', 'Accepted'] | ['s194588738', 's642886022'] | [2940.0, 2940.0] | [18.0, 17.0] | [152, 194] |
p02772 | u985827933 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ["N = int(input())\nA = list(map(int, input().split()))\ncount = 0\nfor i in A:\n if i//3 == 0 or i//5 == 0:\n count += 1\n else:\n count += 0\n \nif count == N:\n print('APPROVED')\nelse:\n print('DENIED')", 'N = int(input())\nA = list(map(int, input().split()))\ncount = 0\nfor i in range(N):\n if A[i]... | ['Wrong Answer', 'Accepted'] | ['s794428348', 's982021301'] | [3060.0, 3064.0] | [20.0, 18.0] | [205, 297] |
p02772 | u992910889 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ["n=int(input())\na=list(map(int,input().split()))\ncnt=0\nwhile True:\n if cnt>=n:\n print('DENIED')\n break\n \n elif a[cnt]%2==0:\n if a[cnt]%3==0 or a[cnt]%5==0:\n cnt+=1\n continue\n else:\n print('DENIED')\n break\n elif cnt==... | ['Wrong Answer', 'Accepted'] | ['s863301526', 's357093721'] | [3060.0, 3064.0] | [17.0, 20.0] | [392, 403] |
p02772 | u993642190 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['N = int(input())\nli = [int(i) for i in input().split()]\n\nis_approved = True\nfor l in li :\n if (l % 2 != 0) :\n continue\n\n if (l % 2 == 0 and l % 3 == 0 and l % 5 == 0) :\n continue\n\n is_approved = False\n break\n\nif (is_approved) :\n print("APPROVED")\nelse :\n print("DENIED"... | ['Wrong Answer', 'Accepted'] | ['s201200996', 's790895621'] | [2940.0, 3060.0] | [19.0, 17.0] | [304, 288] |
p02772 | u995109095 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['\nn=int(input())\nl=list(map(int,input().split()))\nf=1\nfor i in range(n):\n if not l[i]%2:\n if l[i]%3 or l[i]%5 :\n f=0\n break\nif f:\n print("APPROVED")\nelse:\n print("DENIED")\n \n', '\nn=int(input())\nl=list(map(int,input().split()))\nf=1\nfor i in range(n):\n... | ['Wrong Answer', 'Accepted'] | ['s205492482', 's752615456'] | [2940.0, 3060.0] | [17.0, 19.0] | [223, 223] |
p02772 | u995323427 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ['N = int(input())\noddNum = set()\n\nfor x in list(map(int, input().split())):\n if (x % 2 == 0):\n oddNum.add(x)\n\nif (len(oddNum) == 0):\n print("DENIED")\n\nfor o in range(len(oddNum)):\n if ((o % 3 != 0) | (o % 5 != 0)):\n print("DENIED")\n exit()\n\nprint("APPROVED")', 'N = int(inpu... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s021785957', 's911791445', 's262201992'] | [3064.0, 3060.0, 3064.0] | [18.0, 17.0, 18.0] | [287, 243, 231] |
p02772 | u998082063 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ["n = int(input())\ns = map(int, input().split())\nlis = [6, 10, 12, 18, 20, 24, 30, 36, 40, 42, 48, 50, 54, 60, 66, 70, 72, 78, 80, 84, 90, 96, 100, 102, 108, 110, 114, 120, 126, 130, 132, 138, 140, 144, 150, 156, 160, 162, 168, 170, 174, 180, 186, 190, 192, 198, 200, 204, 210, 216, 220, 222, 228, 230, 234, 240, 246, ... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s356421851', 's464145042', 's505903745', 's545147721'] | [3192.0, 3192.0, 3192.0, 3192.0] | [18.0, 17.0, 17.0, 19.0] | [1383, 1278, 1262, 1319] |
p02772 | u999983491 | 2,000 | 1,048,576 | You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria. According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is... | ["N = int(input())\nX = [int(x) for x in input().split()]\nprint(X)\nresult = list(filter(lambda x: x % 2 == 0, X))\ncount = 0\nfor i in result:\n if i % 3 == 0 or i % 5 == 0:\n count += 1\nprint('APPROVED' if count == len(result) else 'DENIED')", 'N = int(input())\nA = list(map(int, input().split()))\nlst = ... | ['Wrong Answer', 'Accepted'] | ['s842261660', 's460930713'] | [3060.0, 3060.0] | [17.0, 18.0] | [245, 255] |
p02773 | u006883624 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['#from math import sqrt\n#from heapq import heappush, heappop\n#from collections import deque\n\nn = int(input())\n\nl = []\nfor _ in range(n):\n s = input()\n l.append(s)\n\nl.sort()\n\nmax_count = 0\ncount = 0\nresults = []\nps = None\nfor s in l:\n if s == ps or ps is None:\n count += 1\n else:\n... | ['Wrong Answer', 'Accepted'] | ['s742709963', 's472362263'] | [20680.0, 20680.0] | [605.0, 629.0] | [652, 640] |
p02773 | u013202780 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['from collections import Counter\n\ninput_line=int(input())\ncount=0\ninput_list=[]\nwhile count < input_line:\n input_list.append(input())\n count+=1\nans_list=[]\nlist_set=set(input_list)\nmax_appeard=Counter(input_list).most_common(1)[0][1]\nprint (max_appeard)\nfor item in list_set:\n appeard=Counter(input_li... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s417091284', 's550362944', 's760122356'] | [49776.0, 49780.0, 32480.0] | [2108.0, 2105.0, 751.0] | [456, 545, 253] |
p02773 | u015418292 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['from collections import Counter\nn = int(input())\ns = [input() for i in range(n)]\n\na = Counter(s)\nprint(type(a))\nb = a.most_common()[0][1]\n\ns = list(set(s)) \n\n\nfor i in s:\n if s[i] == b:\n print(i)\n', 'from collections import Counter\nn = int(input())\ns = [input() for i in range(n)]\n\na = Coun... | ['Runtime Error', 'Runtime Error', 'Wrong Answer', 'Accepted'] | ['s185565825', 's240151960', 's724394908', 's042694832'] | [45084.0, 2940.0, 45040.0, 45036.0] | [416.0, 17.0, 632.0, 721.0] | [238, 233, 222, 232] |
p02773 | u015593272 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['mport collections\n\nN = int(input())\nS = []\n\nfor i in range(N):\n S.append(input())\n\nS.sort()\ncounter = collections.Counter(S)\n\ntmp = counter.most_common()\n\nif (len(tmp) == 1):\n print(tmp[0][0])\nelse:\n for i in range(len(tmp)-1):\n print(tmp[i][0])\n if (tmp[i][1] != tmp[i + 1][1]... | ['Runtime Error', 'Accepted'] | ['s023401328', 's907173571'] | [2940.0, 45116.0] | [17.0, 972.0] | [320, 261] |
p02773 | u018679195 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n=int(input())\ns=[]\nha={}\n\nfor i in range (n):\n s.append(input())\n if (s[i] not in ha.keys()):\n ha[s[i]]=1\n else:\n ha[s[i]]=ha[s[i]]+1\n\nans=sorted(ha.items(),key=lambda x:x[i], reverse=True)\n\nk=ans[0][1]\ni=0\nwhile (i< len(ans) and ans[i][1]==k):\n i+=1\n\nans=ans[:i]\nans.sort... | ['Runtime Error', 'Wrong Answer', 'Accepted'] | ['s204536887', 's339098274', 's873193430'] | [43208.0, 29076.0, 48284.0] | [434.0, 2108.0, 917.0] | [334, 344, 265] |
p02773 | u018771977 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ["n = int(input())\ns = []\nwhile True:\n try:\n s.append(input())\n except EOFError:\n break\n\nword_counter = {}\nfor word in s:\n if word in word_counter:\n word_counter[word] += 1\n else:\n word_counter[word] = 0\n\nresults = sorted(word_counter.items(), key=lambda x: x[1], r... | ['Wrong Answer', 'Accepted'] | ['s417953458', 's600797974'] | [46528.0, 51340.0] | [531.0, 693.0] | [436, 474] |
p02773 | u021019433 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['from itertools import groupby\nfrom iterator import itemgetter\n\na = groupby(sorted(input() for _ in range(int(input()))))\na = [(len(tuple(g)), s) for s, g in a]\nm = max(a, key=itemgetter(0))[0]\nfor k, s in a:\n if k == m:\n print(s)\n', 'from itertools import groupby\nfrom itertools import itemgetter\n\na = ... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted'] | ['s207485902', 's611618305', 's905871454', 's828435530'] | [3060.0, 3060.0, 2940.0, 32476.0] | [17.0, 18.0, 17.0, 611.0] | [234, 235, 166, 169] |
p02773 | u021763820 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['# -*- coding: utf-8 -*-\nN = int(input())\ns = []\nc = []\nd = []\nfor i in range(N):\n S = input()\n s.append(S)\nfor i in range(N):\n c.append(s.count(s[i]))\nfor i in range(N):\n if max(c) == c[i]:\n d.append(s[i])\nd = set(d)\nfor i in range(len(d)):\n print(list(d)[i])', '# -*- coding: utf-... | ['Wrong Answer', 'Accepted'] | ['s201734426', 's509258381'] | [18840.0, 45040.0] | [2104.0, 724.0] | [281, 311] |
p02773 | u023229441 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n=int(input())\nA=[]\nfor i in range(n):\n A.append(input())\nfrom collections import Counter\nC=Counter(A)\nqq=max(C.values())\nans=[]\nfor word,times in C.items():\n if times==qq:\n ans.append(word)\nprint(sorted(ans))', 'n=int(input())\nA=[]\nfor i in range(n):\n A.append(input())\nfrom collections import Co... | ['Wrong Answer', 'Accepted'] | ['s881245582', 's590755224'] | [39312.0, 35472.0] | [617.0, 732.0] | [214, 249] |
p02773 | u024768467 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n=int(input())\ns_list=[input() for _ in range(n)]\n\nimport collections\ns_counter = collections.Counter(s_list)\n\nimport sys\nmax_count = s_counter.most_common()[0][1]\n\ns_list_keys = list(s_counter.keys())\ns_list_values = list(s_counter.values())\n\nlist_ans = []\n\nfor i in range(len(s_list_keys)):\n if s_l... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s301751750', 's505451029', 's781337062'] | [45072.0, 45072.0, 45068.0] | [790.0, 569.0, 768.0] | [471, 374, 442] |
p02773 | u024782094 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n=int(input())\ns1 = []\nfor i in range(n):\n s1.append(input())\ns2=list(set(sorted(s1)))\nN=[]\nfor i in range (len(s2)):\n ni=s1.count(s2[i])\n N.append(ni)\nnm=max(N)\nfor i in range (len(s2)):\n if N[i]==nm:\n print(s2[i])', 'import collections as c\n \nn = int(input())\nalist = [input() for i in range(... | ['Wrong Answer', 'Accepted'] | ['s266909625', 's600995597'] | [31172.0, 49204.0] | [2105.0, 744.0] | [224, 315] |
p02773 | u025287757 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['N = int(input())\ndic = {}\nfor i in range(N):\n s = str(input())\n if not s in dic:\n dic[s] = 1\n else:\n dic[s] += 1\nmax_k_list = [kv[0] for kv in dic.items() if kv[1] == max(dic.values())]\nfor i in max_k_list:\n print(i)', 'import collections\n\nN = int(input())\na = []\nfor i in range(N):\n a.append... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s298492614', 's482451236', 's883728982', 's911859184'] | [32092.0, 35564.0, 35568.0, 35572.0] | [2105.0, 522.0, 787.0, 683.0] | [226, 221, 253, 253] |
p02773 | u025463382 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['import collections as cl\nn = int(input())\ns = []\nfor i in range(n):\n s.append(input())\nh = cl.Counter(s)\nitm = h.items()\n\nm = max(list(h.values()))\n\nmfil = list(filter(lambda x:x[1]==m ,itm))\nsorted(mfil)\n\nfor j in mfil:\n print(j[0])', 'import collections as cl\nfrom operator import itemgetter, at... | ['Wrong Answer', 'Accepted'] | ['s890386979', 's298995099'] | [47724.0, 49944.0] | [968.0, 802.0] | [289, 357] |
p02773 | u025595730 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ["# coding: utf-8\n\n\ndef main():\n n = int(input())\n polls_dict = {}\n for _ in range(n):\n poll = input()\n if poll not in polls_dict:\n polls_dict[poll] = 1\n else:\n polls_dict[poll] += 1\n\n max_poll = max(polls_dict.values())\n \n polls_dict = sorted(... | ['Runtime Error', 'Accepted'] | ['s304044858', 's602680667'] | [32096.0, 44272.0] | [516.0, 693.0] | [588, 500] |
p02773 | u028014940 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['\nn=int(input())\ns=list(input(i) for i in range(n))\n\n# print(s)\nimport collections\nc = collections.Counter(s)\n\nmax_num=max(list(c.values()))\nfor i in range(len(c)):\n if c.most_common()[i][1]==max_num:\n print(c.most_common()[i][0])\n\n else:\n continue', "from collections import Counter\n... | ['Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Wrong Answer', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Accepted'] | ['s013554790', 's250698473', 's267336358', 's286404142', 's328448986', 's415987310', 's536731165', 's599766048', 's878083307', 's055016314'] | [46180.0, 36932.0, 3444.0, 40740.0, 18076.0, 62832.0, 36916.0, 3316.0, 52880.0, 35216.0] | [2106.0, 1442.0, 21.0, 292.0, 1119.0, 2107.0, 1452.0, 23.0, 1365.0, 667.0] | [267, 240, 335, 344, 207, 261, 240, 357, 249, 490] |
p02773 | u033524082 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n=int(input())\ndict={}\nfor i in range(n):\n s=input()\n if s in dict_keys:\n dict[s]=1\n else:\n dict[s]+=1\nitems_sorted = sorted(dict.items(), key = lambda x : x[1])\nvalue=items_sorted[0][0]\ni=0\nwhile(1):\n if items_sorted[i][0]==value:\n print(items_sorted[i][1])\n else:\n ... | ['Runtime Error', 'Accepted'] | ['s935012828', 's177758582'] | [3064.0, 45116.0] | [18.0, 915.0] | [315, 260] |
p02773 | u036340997 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ["n = int(input())\ndic = {}\nm = 0\nfor i in range(n):\n s = input()\n if s in dic:\n dic[s] += 1\n m = max(m, dic[s])\n else:\n dic[s] = 1\n m = max(m, dic[s])\nans = []\nfor s in dic:\n if dic[s] == m:\n ans.append(s)\nprint('\\n'.join(ans))", "n = int(input())\ndic = {}\nm = 0\nfor i in range(n):... | ['Wrong Answer', 'Runtime Error', 'Accepted'] | ['s487048708', 's855813004', 's215702902'] | [34132.0, 32148.0, 34132.0] | [499.0, 619.0, 630.0] | [245, 252, 253] |
p02773 | u036492525 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n= int(input())\ns= [input() for i in range(n)]\np1=list(set(s))\nN=len(p1)\nc=[0]*N\nfor i in range(N):\n\tc[i]=s.count(p1[i])\nm =max(c)\nc1=c.count(m)\nans=[0]\nfor i in range(N):\n\tif c[i]==m:\n\t\tans.append(p1[i])\nans1=sorted(ans)\nfor i in range(c1):\n\tprint(ans1[i])', 'n= int(input())\ns= [input() for i in... | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s191102200', 's560238349', 's907855279'] | [29076.0, 29076.0, 22012.0] | [2105.0, 2105.0, 630.0] | [257, 262, 299] |
p02773 | u038024401 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['import sys\n\nN = int(input())\nS = [None]*N\ncounter = {}\nfor i in range(N):\n tmp = input()\n if tmp in counter:\n counter[tmp] += 1\n else:\n counter[tmp] = 1\n\n#sort by value\ncounter_sorted = sorted(counter.items(), key=lambda x:x[1], reverse = True)\n\nprint\nprint(counter_sorted)\nprin... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s135873037', 's626171220', 's632268221'] | [56988.0, 49948.0, 48860.0] | [877.0, 1027.0, 747.0] | [550, 485, 515] |
p02773 | u039189422 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['from collections import Counter\nN = int(input())\nS = [int(input()) for i in range(N)]\n\ncount = Counter(S)\nmaxnum = max(count.values())\nmaxlist= [i for i,j in count.items() if j==maxnum]\n\nmaxlist.sort()\nprint("/n".join(maxlist))', 'from collections import Counter\nN = int(input())\nS = [input() for i in range... | ['Runtime Error', 'Wrong Answer', 'Accepted'] | ['s855475628', 's871676299', 's376744125'] | [3316.0, 36592.0, 35572.0] | [20.0, 502.0, 614.0] | [227, 222, 225] |
p02773 | u041046014 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['from collections import Counter\nN=int(input())\nll=[input() for i in range(N)]\nll=Counter(ll)\nll=ll.most_common()\nll.sort(key=lambda x:(x[1],x[0]))\nfor i in ll:\n print(i[0])\n', 'from collections import Counter\nN=int(input())\nll=[input() for i in range(N)]\nll=Counter(ll)\nll=ll.most_common()\nfor i in ll:... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s030038062', 's140969789', 's216971037'] | [47312.0, 43476.0, 43468.0] | [986.0, 590.0, 801.0] | [176, 141, 279] |
p02773 | u044964932 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['def main():\n n = int(input())\n ss = {}\n max_s = -1\n for _ in range(n):\n s = input()\n if s not in ss:\n ss[s] = 0\n else:\n ss[s] += 1\n max_s = max(max_s, ss[s])\n\n anss = [s for s in ss if ss[s] == max_s]\n for ans in anss:\n print... | ['Wrong Answer', 'Accepted'] | ['s099637593', 's418513628'] | [32096.0, 45852.0] | [422.0, 784.0] | [350, 396] |
p02773 | u045235021 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['import itertools\nfrom collections import Counter\n\nN=int(input())\na=[input() for i in range(N)]\n\na = sorted(a)\n#print(a)\n\n\ncounter = Counter(a)\n\nmode_v = counter.most_common()[0][-1]\n\n#print(mode_v)\nit = itertools.takewhile(\n lambda kv: kv[-1] == mode_v, sorted(counter.most_common())\n)\n\n\n\nfor k... | ['Wrong Answer', 'Accepted'] | ['s174573401', 's093369690'] | [49028.0, 49428.0] | [1171.0, 1099.0] | [328, 383] |
p02773 | u046961553 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['import collections\ndef resolve_c():\n n = input()\n s_l = [input() for i in range(int(n))]\n c = collections.Counter(s_l)\n for k, v in c.items():\n if v == c.most_common()[0][1]:\n results.append(v)\n else:\n break\n results = sorted(results)\n for r in results:... | ['Runtime Error', 'Accepted'] | ['s567417859', 's248242430'] | [45036.0, 59500.0] | [379.0, 896.0] | [336, 298] |
p02773 | u047197186 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n = int(input())\ndic = {}\nfor i in range(n):\n elem = input()\n if not elem in dic:\n dic[elem] = 1\n else:\n dic[elem] += 1\nmax_ = max(dic.values())\n\nres = []\nfor k, v in dic.items():\n if v == max_:\n res.append(v)\n\nres = sorted(res)\nfor elem in res:\n print(res)', 'n = int(input())\ndic = {}... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s692850727', 's720482078', 's424674411'] | [113628.0, 32096.0, 32988.0] | [2105.0, 457.0, 665.0] | [271, 216, 272] |
p02773 | u047719604 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['from collections import Counter\nn = int(input())\nlst = [(input()) for _ in range(n)]\nlst.sort()\nc = Counter(lst)\nd = c.most_common()\nfor i,j in d:\n print(i)\n ', 'from collections import Counter\nn = int(input())\nlst = [(input()) for _ in range(n)]\nc = Counter(lst)\nd = c.most_common()\ne = d[0][1]\nls... | ['Wrong Answer', 'Accepted'] | ['s536947810', 's343898551'] | [46864.0, 47672.0] | [636.0, 726.0] | [164, 283] |
p02773 | u048176319 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n = int(input())\n\nd = {}\n\nfor i in range(n):\n s = input()\n d[s] = d.get(s, 0) + 1\n\nm = max(d[i] for i in d)\nprint(m, d)\n\nfor j in sorted(d):\n if d[j] == m:\n print(j)', 'n = int(input())\n\nd = {}\n\nfor i in range(n):\n s = input()\n d[s] = d.get(s, 0) + 1\n\nm = max(d[i] for i in d... | ['Wrong Answer', 'Accepted'] | ['s069779667', 's279155546'] | [40668.0, 32096.0] | [774.0, 744.0] | [181, 169] |
p02773 | u049725710 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n=int(input())\na=[str(input()) for i in range(n)]\nb=set(a)\nb=[[i,0]for i in b]\nlenb=range(len(b))\nfor i in lenb:\n for j in a:\n if j==b[i][0]:\n b[i][1]+=1\nmaxb=max(b,key=lambda x:x[1])\nmaxb=maxb[1]\nb=sorted(b,key=lambda x:x[0])\nprint(b)\nfor i in lenb:\n if b[i][1]==maxb:\n print(b[i][0])', 'n... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s124097046', 's279489690', 's296536000', 's511950894', 's574184783', 's621792901', 's700617598', 's702446640', 's991839465', 's068948555'] | [46352.0, 46352.0, 39688.0, 41928.0, 39692.0, 41932.0, 46348.0, 31732.0, 39692.0, 46352.0] | [2106.0, 2106.0, 2106.0, 2106.0, 2106.0, 2106.0, 2106.0, 533.0, 2110.0, 787.0] | [298, 314, 292, 340, 332, 339, 302, 71, 301, 210] |
p02773 | u049979154 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n = int(input())\nwords = {}\n\nfor i in range(n) :\n new_word = input()\n if new_word in words.keys() :\n words[new_word] += 1\n else :\n words[new_word] = 1\n\nmx_freq = max(words.values())\nmx_words = [k for k in words.items() if words[k] == mx_freq]\n\nmx_words.sort()\n\nfor mx_word in mx_w... | ['Runtime Error', 'Accepted'] | ['s583604131', 's321287988'] | [32096.0, 32096.0] | [384.0, 703.0] | [328, 327] |
p02773 | u052221988 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n = int(input())\nwordlist = [input() for i in range(n)]\nwordtuple = tuple(set(wordlist))\nans = []\na = len(wordtuple)\nfor j in range(a) :\n checklist.append(wordlist.count(wordtuple[j]))\nanslist = [i for i, v in enumerate(checklist) if v == max(checklist)]\nfor k in range(len(anslist)) :\n ans.append(wordt... | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s175428686', 's889583317', 's009149218'] | [29076.0, 29076.0, 32096.0] | [319.0, 308.0, 612.0] | [373, 361, 246] |
p02773 | u054514819 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['from collections import Counter\nN = int(input())\nL = [str(input()) for _ in range(N)]\nc = Counter(L)\nfor i, x in enumerate(c.most_common()):\n if i>0 and x[1]!=m:\n break\n print(x[0])\n m = x[1]', 'from collections import Counter\nN = int(input())\nL = [str(input()) for _ in range(N)]\nc = Counter(L)\nans ... | ['Wrong Answer', 'Accepted'] | ['s523469401', 's744987493'] | [46888.0, 45036.0] | [624.0, 786.0] | [197, 244] |
p02773 | u054622560 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ["import sys\nimport collections\nN = int(input())\nstrs = []\nfor _ in range(N):\n s = input()\n strs.append(s)\n#print('strs', strs)\nc = collections.Counter(strs)\nmaxv = -1\nans = []\nfor k , v in c.most_common():\n if v != maxv and maxv != -1:\n break\n ans.append(k)\n maxv = v\nfor a in sorted(ans, revers... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s687261192', 's725633357', 's755516152', 's886540171'] | [47076.0, 46836.0, 45036.0, 45040.0] | [740.0, 602.0, 431.0, 751.0] | [321, 260, 209, 307] |
p02773 | u057065089 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ["def main():\n d = {}\n N = int(input())\n for i in range(N):\n s = input()\n d.setdefault(s, 1)\n d[s] += 1\n \n d = sorted(d.items())\n d = sorted(d, key=lambda x:x[1], reverse=True)\n for i in range(N):\n print(d[i][0])\n\nif __name__ == '__main__':\n main()\n", "... | ['Runtime Error', 'Accepted'] | ['s995748593', 's039097401'] | [46640.0, 46700.0] | [591.0, 605.0] | [299, 363] |
p02773 | u057415180 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n = int(input())\ns = [input() for _ in range(n)]\nimport collections\nc = collections.Counter(s)\nd = c.most_common()\ne = [d[0][0]]\nfor i in range(len(d)-1): \n if d[0][1] == d[i+1][1]:\n e.append(d[i+1][0]) \ne.sort()\nprint(repr(e)) ', 'n = int(input())\ns = [input() for _ in range(n)]\nimport col... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s620133986', 's789869384', 's832339327'] | [51980.0, 46892.0, 50312.0] | [645.0, 611.0, 664.0] | [322, 234, 327] |
p02773 | u057483262 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['import sys\nimport math\n\nfrom collections import defaultdict\nfrom collections import deque\ndef load(vtype=int):\n return vtype(input().strip())\ndef load_list(seplator=" ", vtype=int):\n return [vtype(v) for v in input().strip().split(seplator)]\ndef exit():\n import sys\n sys.exit(0)\ndef perm_sub(li... | ['Wrong Answer', 'Accepted'] | ['s513321280', 's335016426'] | [35572.0, 36972.0] | [627.0, 804.0] | [2339, 2347] |
p02773 | u059684599 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n = int(input())\ns = [input() for _ in range(n)]\n\nfrom collections import Counter\n\nc = Counter(s)\nm = max(c.values())\nans = []\nfor k,v in c.items():\n if v == m:\n ans.append(k)\nfor i in ans:\n print(i)', 'n = int(input())\ns = [input() for _ in range(n)]\n\nfrom collections import Counter\n\nc ... | ['Wrong Answer', 'Accepted'] | ['s002957867', 's527038842'] | [35464.0, 35476.0] | [533.0, 611.0] | [212, 223] |
p02773 | u061539997 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n = int(input())\ns = {}\nfor i in range(n):\n tmp = input()\n if not tmp in s.keys():\n s[tmp] = 1\n else:\n s[tmp] += 1\nm = 0\nl = []\nfor i in sorted(s.items(), key=lambda x:x[1], reverse=True):\n if m < i[1]:\n m = i[1]\n l.append(i[0])\n else:\n break\n\nfor i i... | ['Wrong Answer', 'Accepted'] | ['s567813729', 's235415685'] | [43228.0, 43228.0] | [441.0, 773.0] | [326, 328] |
p02773 | u061984624 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n = int(input())\na = dict()\nfor _ in range(n):\n s = input()\n if s in a:\n a[s] += 1\n else:\n a[s] = 1\n\nM = max(a.values())\nfor s in a:\n if a[s] == M:\n print(s)\n', 'n = int(input())\na = dict()\nfor _ in range(n):\n s = input()\n if s in a:\n a[s] += 1\n else... | ['Wrong Answer', 'Accepted'] | ['s737701775', 's263919040'] | [32096.0, 32096.0] | [465.0, 622.0] | [191, 243] |
p02773 | u062808720 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['import collections\n\nn = int(input())\nl = []*n\n\nfor x in range(0, n) :\n l.append(input())\n\nl_sorted = sorted(l)\nc = collections.Counter(l_sorted)\nmc = c.most_common()\n\npre_v = 0\nans = []\nfor m in mc :\n k = m[0]\n v = m[1]\n if v < pre_v :\n break\n pre_v = v\n ans.append(k)\n\na... | ['Wrong Answer', 'Accepted'] | ['s015983002', 's549271363'] | [55152.0, 50788.0] | [873.0, 879.0] | [339, 356] |
p02773 | u064264248 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['N = int(input())\n\nd_count = {}\nfor i in range(N):\n S = str(input())\n d_count.setdefault(S, 0)\n d_count[S] = d_count[S] + 1\nprint(d_count)\n\nmax = 0\nmaxlist = []\nfor S in d_count:\n if(max < d_count[S] ):\n max = d_count[S]\n maxlist = [S]\n if(max == d_count[S]):\n maxlis... | ['Wrong Answer', 'Accepted'] | ['s736739024', 's414139340'] | [46940.0, 43996.0] | [945.0, 891.0] | [401, 386] |
p02773 | u064445353 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['import collections\n\nn = int(input())\ns = [input() for i in range(n)]\nc = collections.Counter(s)\n\nm = max(c.values())\n\nans = [k for k, v in c.items() if m == v]\nans.sort()\n\nprint(i for i in ans)', 'n = int(input())\n\ns = {}\ni = 0\nwhile n > i:\n s_tmp = input()\n if s.get(s_tmp):\n s[s_tmp] +... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s361209526', 's641244022', 's857229064', 's015811873'] | [35568.0, 32096.0, 32096.0, 45040.0] | [558.0, 2104.0, 427.0, 711.0] | [193, 267, 201, 186] |
p02773 | u066455063 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['from collections import Counter\n\nN = int(input())\nS = [input() for i in range(N)]\n\ncnt = Counter(S)\nval = list(cnt.values())\nmost = val[-1]\n\nans = []\nfor i in cnt:\n if cnt[i] == most:\n ans.append(i)\n\nans.sort()\nfor i in range(len(ans)):\n print(ans[i])\n', 'from collections import Counter\... | ['Wrong Answer', 'Accepted'] | ['s772760708', 's053566658'] | [35572.0, 35572.0] | [710.0, 759.0] | [265, 282] |
p02773 | u067447457 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['import collections\nl=[]\nn=int(input())\nfor i in range(n):\n l.append(input())\nc=collections.Counter(l)\nmax_list=[kv[0] for kv in c.items() if kv[1]==max(c.values())]\n\nfor j in max_list:\n print(j)', 'from collections import Counter\n\nn=int(split())\nl=[input() for i in range(n)]\nc=Counter(l)\nd=max(c.value... | ['Wrong Answer', 'Runtime Error', 'Runtime Error', 'Accepted'] | ['s228133291', 's378510379', 's435446612', 's061981502'] | [35568.0, 3316.0, 3316.0, 38476.0] | [2105.0, 20.0, 21.0, 414.0] | [196, 196, 213, 195] |
p02773 | u068142202 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n = int(input())\ns = [input() for i in range(n)]\nans = []\nout = []\nword_list = list(set(s))\n\nfor i in word_list:\n ans.append([s.count(i), i])\n\nans.sort(reverse = True)\n\nfor j in ans:\n if j[0] == ans[0][0]:\n out.append(j[1])\n\nout.sort(reverse = True)\nfor k in out:\n print(k)\n', 'n = int(input())... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Time Limit Exceeded', 'Accepted'] | ['s025212785', 's464635105', 's464694714', 's732391955', 's681927452'] | [29076.0, 29068.0, 55788.0, 29332.0, 38060.0] | [2105.0, 2105.0, 2106.0, 2105.0, 598.0] | [280, 215, 216, 240, 264] |
p02773 | u068944955 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['N = int(input())\nD = dict()\nfor _ in range(N):\n cand = input()\n if cand not in D:\n D[cand] = 1\n else:\n D[cand] += 1\nmx = max(D.values())\nA = sorted(D.items(), key=lambda x: -x[1])\n\nfor k, m in A:\n if m == mx:\n print(k)\n else:\n exit()\n', 'N = int(input())\nD =... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s545049695', 's973056524', 's938602310'] | [44888.0, 44892.0, 47576.0] | [582.0, 571.0, 705.0] | [277, 282, 331] |
p02773 | u074687136 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['N = int(input())\nwords = {}\nfor i in range(N):\n name = input()\n if name not in words:\n words[name] = 1\n elif name in words:\n words[name] += 1\n \nres_name = []\nfor i in res_dict.keys():\n if res_dict[i] == max(res_dict.values()):\n res_name.append(i)\nres_name = sorted(res_name)\nfor i in res_... | ['Runtime Error', 'Runtime Error', 'Wrong Answer', 'Accepted'] | ['s012302721', 's079360185', 's931917580', 's137048130'] | [32224.0, 32096.0, 5012.0, 32984.0] | [373.0, 374.0, 2104.0, 626.0] | [320, 306, 441, 321] |
p02773 | u075109824 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n = int(input())\ns = []\nfor i in range(0, n):\n s.append(input())\nmy_dict = {i:s.count(i) for i in s}\nanswer = []\nitemMaxValue = max(my_dict.items(), key=lambda x: x[1])\nfor key, value in my_dict.items():\n if value == itemMaxValue[1]:\n answer.append(key)\n\nfor x in answer:\n print(x)', 'from ... | ['Wrong Answer', 'Accepted'] | ['s877298465', 's632267818'] | [19104.0, 45268.0] | [2105.0, 1003.0] | [297, 389] |
p02773 | u075303794 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n = int(input())\ndic = {}\n\nfor i in range(n):\n temp = input()\n try:\n dic[temp] += 1\n except:\n dic[temp] = 0\n\ndic = dict(sorted(dic.items(), key=lambda x: x[0]))\n\nfor i in dic.keys():\n print(i)', "from collections import Counter\n\nn = int(input())\ns = [input() for _ in range(n)]\n\ncounter = C... | ['Wrong Answer', 'Accepted'] | ['s245337394', 's567154848'] | [66140.0, 35824.0] | [898.0, 569.0] | [202, 237] |
p02773 | u077291787 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['# C - Poll\nfrom collections import Counter\n\n\ndef main():\n _, *S = open(0).read().split()\n cnt = Counter(S)\n max_votes = max(cnt)\n ans = [k for k, v in cnt.items() if v == max_votes]\n ans.sort()\n print("\\n".join(ans))\n\n\nif __name__ == "__main__":\n main()\n', '# C - Poll\nfrom collec... | ['Wrong Answer', 'Accepted'] | ['s105467839', 's550787307'] | [38520.0, 38392.0] | [111.0, 278.0] | [275, 284] |
p02773 | u078816252 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['N = int(input())\nname = [input() for i in range(N)]\nimport collections\n\nc = collections.Counter(name)\nvalues, counts = zip(*c.most_common(N))\nmaxim = counts[0]\nanswer = []\nfor val, cnt in zip(values,counts):\n if ( cnt == maxim):\n answer.append(val)\n else:\n break\nsorted(answer)\nfor i in answer:\n... | ['Wrong Answer', 'Accepted'] | ['s218122401', 's399540796'] | [59536.0, 59536.0] | [874.0, 861.0] | [403, 412] |
p02773 | u079022693 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['import sys\ninput=sys.stdin.readline\ndef main():\n N=int(input())\n S=[""]*N\n result={}\n for i in range(N):\n S[i]=input().strip()\n if S[i] not in result:\n result[S[i]]=1\n else:\n result[S[i]]+=1\n\n result=sorted(result.items())\n print(result)\n ... | ['Wrong Answer', 'Accepted'] | ['s883101176', 's481227908'] | [43992.0, 47636.0] | [824.0, 737.0] | [541, 388] |
p02773 | u080364835 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ["sl_s = sorted(list(set(sl)))\n\nif len(sl_s) == 1:\n print(sl[0])\nelse:\n ans = []\n count = 1\n for s in sl_s:\n if sl.count(s) == count and ans.count(s) == 0:\n ans.append(s)\n elif sl.count(s) > count and ans.count(s) == 0:\n ans.clear()\n ans.append(s)\n... | ['Runtime Error', 'Accepted'] | ['s484711388', 's348281597'] | [3060.0, 35960.0] | [17.0, 552.0] | [362, 291] |
p02773 | u082978753 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['import collections\nN = int(input())\nS_lis = []\nfor i in range(N):\n S_lis.append(input())\n\nunique_S_lis = list(set(S_lis))\nhaha = collections.Counter(S_lis)\nmaxind = [i for i, x in enumerate(list(haha.values())) if x == max(list(haha.values()))]\nlis_ans = sorted([unique_S_lis[i] for i in maxind])\n\nfor an... | ['Wrong Answer', 'Accepted'] | ['s319797286', 's717262695'] | [45356.0, 49424.0] | [2105.0, 699.0] | [337, 435] |
p02773 | u085717502 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['#!/usr/bin/env python\n# coding: utf-8\n\n# In[12]:\n\n\nimport collections\n\n\n# In[13]:\n\n\nN = int(input())\nS = []\nfor _ in range(N):\n S.append(input())\n\n\n# In[14]:\n\n\nmylist = collections.Counter(S).most_common()\ncnt_tmp = mylist[0][1]\nfor word, cnt in mylist:\n if cnt != cnt_tmp:\n break... | ['Wrong Answer', 'Accepted'] | ['s748571210', 's596575661'] | [49448.0, 49256.0] | [398.0, 508.0] | [343, 351] |
p02773 | u086503932 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['N=int(input())\nA = [input() for x in range(N)]\nmax=-1\nfor a in set(A):\n if A.count(a)>max:\n max=A.count(a)\n\nfor b in set(A):\n if A.count(b)==max:\n print(b)', 'N=int(input())\nd={}\nfor i in range(N):\n tmp = input()\n if tmp in d:\n d[tmp] += 1\n else:\n d[tmp] = 1\n\nmax_v=max(d.values())\n... | ['Wrong Answer', 'Accepted'] | ['s314124967', 's218135085'] | [29100.0, 46932.0] | [2105.0, 853.0] | [163, 219] |
p02773 | u088115428 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['N = int(input())\nl = [input() for _ in range(N)]\nl.sort()\nl2 = []\nfor i in range(0,N-1):\n if (l[i]==l[i+1]):\n l2.append(l[i])\nans=list(set(l2))\nif len(l2)==0:\n for k in range(0,N):\n print(l[k])\nfor j in range(0,len(l2)):\n print(ans[j])', 'from collections import Counter\nN = int(inp... | ['Runtime Error', 'Accepted'] | ['s843687366', 's251628701'] | [20796.0, 32480.0] | [595.0, 684.0] | [258, 169] |
p02773 | u088863512 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['# -*- coding: utf-8 -*-\nimport sys\nfrom collections import deque, defaultdict\nfrom math import sqrt, factorial\n# def input(): return sys.stdin.readline()[:-1] # warning not \\n\n\n\n\n\ndef solve():\n n = int(input())\n d = defaultdict(int)\n mx = 0\n for _ in range(n):\n s = input()\n d... | ['Wrong Answer', 'Accepted'] | ['s735929128', 's323814114'] | [35376.0, 35636.0] | [384.0, 481.0] | [707, 689] |
p02773 | u089376182 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['from collections import defaultdict\n\nn = int(input())\n\nd = defaultdict(int)\n\nfor _ in range(n):\n d[input()] += 1\n\nn = max(d.values())\n \nfor k, v in d.items():\n if v==n:\n print(k)', 'from collections import defaultdict\n\nn = int(input())\nd = defaultdict(int)\n\nfor _ in range(n):\n d[inpu... | ['Wrong Answer', 'Accepted'] | ['s524059162', 's328775806'] | [32480.0, 44664.0] | [589.0, 927.0] | [190, 224] |
p02773 | u093861603 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['import collections\nn=input()\ns=[]\nfor i in range(n):\n s.append(input())\nc=collections.Counter(s).most_common()\n\n\nprint(c[0][0])\nmx=c[0][1]\nfor i in range(1,len(c)):\n if c[i][1]==mx:\n print(c[i][0])\n else:\n exit()\n ', 'import collections\nn=int(input())\ns=[]\nfor i in range(n)... | ['Runtime Error', 'Accepted'] | ['s769465675', 's956357981'] | [3316.0, 45040.0] | [21.0, 710.0] | [240, 290] |
p02773 | u094425865 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n = int(input())\nsi = []\nfor i in range(n):\n si.append(input())\n\nwkmax = wk = 0\nb = c = []\nb = list(set(si))\nfor i in range(len(b)):\n c.append([b[i],[0]])\n\nfor j in range(len(c)):\n wk = si.count(c[j][0])\n c[j][1] = wk\n wkmax = max(wkmax,wk)\n\nfor i in range(len(c)):\n if c[i][1] == wk... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s212642988', 's751827709', 's987082056'] | [58252.0, 32144.0, 44196.0] | [2108.0, 571.0, 958.0] | [328, 251, 290] |
p02773 | u101350975 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['import collections\nN = int(input())\nS = [input() for i in range(N)]\nc = collections.Counter(S)\nl = c.most_common()\nn, m = l[0]\nfor i, j in l:\n if j == m:\n print(i)\n \n', 'import collections\nN = int(input())\nS = [input() for i in range(N)]\nc = collections.Counter(S)\nl = c.most_common()... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s454291501', 's850528442', 's584485583'] | [46860.0, 45808.0, 49172.0] | [528.0, 638.0, 729.0] | [186, 206, 228] |
p02773 | u104005543 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n = int(input())\n\nS = list(str(input()) for i in range(n))\nSortedS = sorted(S) \ns = [] \nS2 = [] \ncount = 1\nfor i in range(n - 1):\n if i == n - 2 and SortedS[i] != SortedS[i + 1]:\n s.append(count)\n s.append(1)\n S2.append(SortedS[i])\n S2.append(SortedS[i + 1])\n \n else:... | ['Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s179276218', 's198479215', 's466417744', 's741903357', 's118381581'] | [22548.0, 24376.0, 22932.0, 31120.0, 24340.0] | [607.0, 819.0, 736.0, 775.0, 788.0] | [704, 698, 694, 719, 695] |
p02773 | u105302073 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ['n = int(input())\nS = [input() for _ in range(n)]\nd = {}\nm = 0\nfor s in S:\n if s in d:\n d[s] += 1\n m = max(m, d[s])\n else:\n d[s] = 1\n m = 1\nsd = sorted(d.items(), key=lambda x: x[1], reverse=True)\nfor k, v in sd:\n if v != m:\n break\n print(k)\n', 'n = int(in... | ['Wrong Answer', 'Accepted'] | ['s049118674', 's048648410'] | [46480.0, 48908.0] | [524.0, 792.0] | [288, 321] |
p02773 | u106311097 | 2,000 | 1,048,576 | We have N voting papers. The i-th vote (1 \leq i \leq N) has the string S_i written on it. Print all strings that are written on the most number of votes, in lexicographical order. | ["#!python3.4\n# -*- coding: utf-8 -*-\n# abc155/abc155_c\nimport sys\nimport collections\n\ns2nn = lambda s: [int(c) for c in s.split(' ')]\nss2nn = lambda ss: [int(s) for s in list(ss)]\nss2nnn = lambda ss: [s2nn(s) for s in list(ss)]\ni2s = lambda: sys.stdin.readline().rstrip()\ni2n = lambda: int(i2s())\ni2nn = lamb... | ['Wrong Answer', 'Accepted'] | ['s164386048', 's658778637'] | [45420.0, 33768.0] | [524.0, 572.0] | [716, 810] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.