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 |
|---|---|---|---|---|---|---|---|---|---|---|
p03030 | u556594202 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n=int(input())\ns=[]\nfor i in range(n):\n s.append(input().split()+[str(i+1)])\n \ns=sorted(s)\n\nfor i in range(n):\n print(s[i][-1])\n', 'n=int(input())\ns=[]\nfor i in range(n):\n s.append(input().split()+[str(i+1)])\nprint(s)\ns=sorted(s)\nprint(s)\nfor i in range(n):\n print(s[i][-1])\n', 'n=int(... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s026059386', 's184091958', 's658850382', 's855240359'] | [9104.0, 9156.0, 9184.0, 9172.0] | [28.0, 25.0, 31.0, 27.0] | [137, 149, 189, 171] |
p03030 | u559048291 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['\nN = int(input())\n\nlist = []\n\nfor i in range(N):\n A, B = input().split()\n\n A = A + "000000000000"\n A = A[:10]\n B = str(2000-int(B))+str(i+1001)\n list.append(A+B)\n\nlist = merge_sort(list)\n\nfor i in list:\n print(int(i[-3:]))\n', 'def merge_sort(arr):\n if len(arr) <= 1:\n ret... | ['Runtime Error', 'Accepted'] | ['s135399293', 's743977066'] | [2940.0, 3064.0] | [19.0, 18.0] | [241, 1340] |
p03030 | u560867850 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ["\na = sorted([input().split() + [str(i+1)] for i in range(n)])\n\na.append(['end', '0', '0'])\n\ntmp = []\nans = []\n\nfor i in range(n):\n tmp.append(a[i])\n if a[i][0] != a[i+1][0]:\n ans.append(sorted(tmp, key=lambda x: int(x[1]), reverse=True))\n tmp = []\n\n[print(c[2]) for c in ans[0]]\n", "... | ['Runtime Error', 'Accepted'] | ['s485758812', 's349722079'] | [3064.0, 3064.0] | [17.0, 18.0] | [299, 382] |
p03030 | u562015767 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nS = []\ncnt = 0\nfor _ in range(N):\n cnt += 1\n i,p = input().split()\n S.append([i,int(p),cnt+1])\n\nS.sort(reverse = True)\n\nfor i in S:\n print(i[2])', 'N = int(input())\nS = []\ncnt = 0\nfor _ in range(N):\n cnt += 1\n i,p = input().split()\n S.append([i,int(p),cnt])\n\nS.so... | ['Wrong Answer', 'Accepted'] | ['s712103951', 's632826516'] | [3060.0, 3060.0] | [17.0, 18.0] | [171, 180] |
p03030 | u566297428 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['my_list = []\nfor i in range(1,N+1):\n l = list((input().split()))\n l.append(i)\n my_list.append(l)\n\nmy_list2 = sorted(my_list, key=lambda x:(x[0],-int(x[1])))\nfor i in my_list2:\n print(i[2])\n\n', 'N = int(input())\nmy_list = []\nfor i in range(1,N+1):\n l = list((input().split()))\n l.append(i)... | ['Runtime Error', 'Accepted'] | ['s548293759', 's400094628'] | [8752.0, 9132.0] | [23.0, 27.0] | [200, 218] |
p03030 | u568855891 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['from operator import itemgetter\n\nn = int(input())\ne = [[i for i in input().split()] for j in range(n)]\nfor i in range(n):\n e(i).append(i)\nrestaurant = sorted(e,key=itemgetter(1),reverse=True)\nrestaurant.sort(key=itemgetter(0))\n\nfor i in range(n):\n print(restaurant[i][2]+1)\n ', 'n = input()\na = []... | ['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Accepted'] | ['s234271053', 's263639350', 's267849430', 's380647439', 's401174337', 's487154098', 's494151842', 's519814606', 's571918317', 's798002150', 's821014588', 's654509859'] | [3060.0, 3060.0, 3064.0, 3060.0, 3064.0, 3060.0, 3060.0, 3064.0, 3064.0, 3064.0, 3060.0, 3060.0] | [18.0, 17.0, 18.0, 18.0, 20.0, 18.0, 18.0, 18.0, 18.0, 19.0, 18.0, 17.0] | [284, 196, 189, 245, 275, 198, 201, 276, 276, 276, 174, 200] |
p03030 | u569280127 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\nrs = [input().split() for _ in range(n)]\nrs = [(r, int(p)) for r, p in rs]\nsrs = sorted(sorted(rs, key=lambda p: p[1]), key=lambda p: p[0])\n\nfor p in rs:\n print(srs.index(p)+1)', 'n = int(input())\nrs = [input().split() for _ in range(n)]\nrs = [(r, int(p)) for r, p in rs]\nsrs = sorted(sorted... | ['Wrong Answer', 'Accepted'] | ['s384704000', 's605524594'] | [3060.0, 3060.0] | [17.0, 19.0] | [194, 209] |
p03030 | u569776981 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nS_list = []\nP_list = []\nc = []\n\nfor i in range(N):\n S, P = input().split()\n S_list.append(S)\n P_list.append(int(P))\n\nm = S_list\nm = list(set(m))\nm = sorted(m)\nprint(m)\nn = 0\na = []\nb = []\nfor i in m:\n for j in range(N):\n if i == S_list[j]:\n a.append(j... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s176330394', 's705948498', 's159702057'] | [9244.0, 9084.0, 8992.0] | [29.0, 29.0, 27.0] | [686, 691, 666] |
p03030 | u571969099 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\na = []\nfor i in range(n):\n s, p = input().split()\n a.append([s,-int(p),i])\na.sort()\nfor i in a:\n print(i[-1])\n', 'n = int(input())\na = []\nfor i in range(n):\n s, p = list(map(int, input().split()))\n a.append([s,-p,i])\na.sort()\nfor i in a:\n print(i[-1])\n', 'n = int(input())\na = [... | ['Wrong Answer', 'Runtime Error', 'Accepted'] | ['s135015540', 's940354880', 's316855236'] | [3060.0, 2940.0, 3060.0] | [17.0, 17.0, 17.0] | [130, 141, 131] |
p03030 | u572012241 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\nspi = []\nfor i in range(n):\n s, p = map(input().split())\n spi.append((s,-int(p), i))\nspi = sorted(spi)\nfor s, p, i in spi:\n print(i+1)', 'n = int(input())\nspi = []\nfor i in range(n):\n s, p = input().split()\n spi.append((s,-int(p), i))\nspi = sorted(spi)\nfor s, p, i in spi:\... | ['Runtime Error', 'Accepted'] | ['s565086405', 's375165794'] | [2940.0, 3060.0] | [17.0, 17.0] | [160, 155] |
p03030 | u572193732 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nSP = []\nfor i in range(N):\n S, P = map(str, input().split())\n SP.append([S, int(P), i+1])\n\nSP.sort(key = lambda x:x[1], reverse=True)\nSP.sort(key = lambda x:x[0])\n\nfor e in SP:\n print(e[2])\n \nprint(SP)', 'N = int(input())\nSP = []\nfor i in range(N):\n S, P = map(str, input... | ['Wrong Answer', 'Accepted'] | ['s011503175', 's561656746'] | [3064.0, 3060.0] | [18.0, 18.0] | [230, 215] |
p03030 | u572343785 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n=int(input())\n\nsp=[]\nfor i in range(n):\n a=list(map(str,input().split()))\n a.append(i+1)\n sp.append(a)\n \nsp=sorted(sp,key=lambda x:(x[0],x[1]))\n\nfor i in range(len(sp)):\n print(sp[i][2])\n', '\nn=int(input())\n\nsp=[]\nfor i in range(n):\n a=list(map(str,input().split()))\n a.append(i... | ['Wrong Answer', 'Accepted'] | ['s051834047', 's669623222'] | [3060.0, 3060.0] | [18.0, 18.0] | [203, 256] |
p03030 | u573272932 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nLis = []\nfor i in range(N):\n\tS, P = input().split()\n\tLis.append([i+1, S, int(P)])\nprint (Lis)\nLis = sorted(Lis, key = lambda x: (x[1], -x[2]))\nprint (Lis)\nfor i in range(N):\n\tprint(Lis[i][0])', 'N = int(input())\nLis = []\nfor i in range(N):\n\tS, P = input().split()\n\tLis.append([i+1, S... | ['Wrong Answer', 'Accepted'] | ['s706064759', 's499344780'] | [3064.0, 3064.0] | [17.0, 17.0] | [208, 184] |
p03030 | u577138895 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = input()\nlst = []\nfor i in range(N):\n s, p = map(int, input().split())\n lst.append([s, p])\n lst_2 = sort(key = lambda x : (x[0], -1 * int(x[1])))\n \nfor i in lst_2:\n print(i[2] + 1)', 'N = input()\nlst = []\nfor i in range(N):\n s, p = map(int, input().split())\n lst.append([s, p, i])\n lst_2 = sort... | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s311409645', 's312092267', 's503161641'] | [2940.0, 3060.0, 3060.0] | [17.0, 17.0, 20.0] | [188, 191, 193] |
p03030 | u580093517 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['a = []\nn = int(input())\nfor i in range(n):\n key,value = input().split()\n a.append((key,value,int(i+1)))\na.sort(key=lambda x:(x[0],not x[1]))\nfor i in range(n):\n print(a[i][2])', 'n = int(input())\nsp = []\nfor i in range(n):\n s,p = input().split()\n sp.append([s,int(p),i+1])\nsp.sort(key = lamb... | ['Wrong Answer', 'Accepted'] | ['s633266844', 's830302546'] | [3060.0, 3060.0] | [18.0, 17.0] | [184, 163] |
p03030 | u580697892 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['# coding: utf-8\nn = int(input())\nll = []\nd = {}\nin_k = []\nfor i in range(n):\n s, p = map(str, input().split())\n if not s in d:\n d[s] = [[int(p), i+1]]\n else:\n d[s].append([int(p), i+1])\n if not s in in_k:\n in_k.append(s)\ntmp = 1\nnum = 1\nkeys = sorted(d.keys())\nfor k in... | ['Wrong Answer', 'Accepted'] | ['s272784316', 's449869768'] | [3064.0, 3064.0] | [18.0, 18.0] | [608, 608] |
p03030 | u582543083 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\ndi = {}\nli = []\nfor x in range(n):\n input_data = list(input().split())\n if input_data[0] not in di:\n di[input_data[0]] = {int(input_data[1]): x}\n li.append(input_data[0])\n else:\n di[input_data[0]][int(input_data[1])] = x\n\nli.sort()\nprint(di)\nfor res in li:\n... | ['Wrong Answer', 'Accepted'] | ['s437828355', 's730775832'] | [3064.0, 3060.0] | [18.0, 18.0] | [453, 443] |
p03030 | u586754007 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nL=[]\n\nfor i in range(N):\n a, b = input().split()\n b = int(b)\n lis = []\n lis.append(a)\n lis.append(b)\n lis.append(i)\n L.append(lis)\nL.sort()\nfor i in L:\n print(i[2])', 'N = int(input())\nL=[]\n\nfor i in range(N):\n a, b = input().split()\n b = int(b)\n lis = []\n lis.append(a... | ['Wrong Answer', 'Accepted'] | ['s245035692', 's970958852'] | [3060.0, 3060.0] | [17.0, 17.0] | [189, 193] |
p03030 | u589753618 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nsp = {}\nfor i in range(N):\n s, p = input().split()\n p = int(p)\n if s not in sp:\n sp[s] = []\n sp[s].append(p)\n\nsp = sorted(sp.items(), key=lambda x:x[0])\n\nfor s in sp:\n for pp in s[1]:\n print("{} {}".format(s[0], pp))', 'N = int(input())\nsp = {}\nco = 1\nfor ... | ['Wrong Answer', 'Accepted'] | ['s639956163', 's455849348'] | [3064.0, 3064.0] | [17.0, 18.0] | [262, 306] |
p03030 | u595375942 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n=int(input())\nL=[]\nfor i in range(n):\n s,p=input().split()\n L.append(s,-int(p),i+1)\nfor l in sorted(L):\n print(l[2])', 'n=int(input())\nL=[]\nfor i in range(n):\n s,p=input().split()\n L.append([s,-int(p),i+1])\nfor l in sorted(L):\n print(l[2])'] | ['Runtime Error', 'Accepted'] | ['s876577553', 's006738643'] | [2940.0, 3060.0] | [17.0, 17.0] | [126, 128] |
p03030 | u599114793 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\na = []\nfor i in range(1, n+1):\n s,p = map(str,input().split())\n a.append((s,int(p),i))\na.sort()\nprint(a)\nans = [a[0][2]]\nk = 0\nfor i in range(1,n):\n if a[i-1][0] == a[i][0]:\n ans.insert(k,a[i][2])\n else:\n k = i\n ans.append(a[i][2])\n\nfor i in range(n):\... | ['Wrong Answer', 'Accepted'] | ['s255681834', 's357028621'] | [3064.0, 3064.0] | [17.0, 18.0] | [323, 314] |
p03030 | u599925824 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\ntown_names = dict()\nassessments = []\nfor x in range(N):\n if x!=N:\n SP = input().split()\n assessments.append(SP[1])\n town_names.setdefault(SP[0],[]).append(assessments.index(SP[1])+1)\n else:\n break\nresult = []\nfor t in sorted(town_names):\n tmp = []\n for pointer in town_nam... | ['Wrong Answer', 'Accepted'] | ['s433282974', 's059767941'] | [3064.0, 3064.0] | [17.0, 18.0] | [464, 478] |
p03030 | u600402037 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['a = [int(input()) for i in range(1)]\nn = a[0]\nrestaurants = [list(input().split()) for i in range(n)]\n#print(restaurants)\n\nsorted_r = sorted(restaurants, key=lambda x: int(x[1]), reverse=True)\n\nsorted_r = sorted(restaurants, key=lambda x: x[0])\n\n\nfor s in sorted_r:\n print(restaurants.index(s) + 1)', '# co... | ['Wrong Answer', 'Accepted'] | ['s990715496', 's362614300'] | [3060.0, 3064.0] | [17.0, 17.0] | [331, 314] |
p03030 | u600717568 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N=int(input())\nList=[[i+1]+input().split() for i in range(N)]\nList.sort(key=lambda x:(x[1],int(x[2])))\nfor s,r,t in List:\n print(s)', 'N=int(input())\nList=[[i+1]+input().split() for i in range(N)]\nList.sort(key=lambda x:(x[1],-int(x[2])))\nfor s,r,t in List:\n print(s)'] | ['Wrong Answer', 'Accepted'] | ['s432559028', 's583434259'] | [3060.0, 3316.0] | [19.0, 20.0] | [140, 141] |
p03030 | u602677143 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ["n,m = map(int,input().split())\nls = []\nswitch = []\nfor i in range(n):\n switch.append(i+1)\nfor i in range(m):\n ks = list(map(int,input().split()))\n ls.append(ks)\np = list(map(int,input().split()))\n\n\npattern = []\nfor i in range(2**n):\n pattern.append(list(bin(i)[2:].zfill(n)))\n\nans = 0\n\nfor... | ['Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s663812903', 's680688065', 's988947078', 's106168091'] | [3064.0, 3064.0, 3064.0, 3060.0] | [17.0, 18.0, 18.0, 18.0] | [664, 703, 485, 149] |
p03030 | u602860891 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\ninfo_list = list()\nfor i in range(N):\n S, P = input().split()\n info_list.append((i + 1, S, int(P)))\n\ninfo_list.sort(key=lambda x: (x[1], -x[2]))\nprint(info_list)\nfor info in info_list:\n print(info[0])\n', 'N = int(input())\ninfo_list = list()\nfor i in range(N):\n S, P = input().... | ['Wrong Answer', 'Accepted'] | ['s784474618', 's291967785'] | [3060.0, 3060.0] | [17.0, 18.0] | [227, 211] |
p03030 | u603324902 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\n\nl = []\nfor i in range(n):\n x,y = map(str,input().split())\n l.append((x,y, i))\n\n\nL = []\n\nfor i in range(n):\n L.append((l[i][0], int(l[i][1]), l[i][2]))\n\nL.sort(key = lambda L:L[1])\n\nL.sort(key = lambda L:L[0])\n\nfor i in range(n):\n print(L[n][2] + 1)\n\n', 'n = int(input())\n\nl ... | ['Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s073531649', 's762311875', 's970379836', 's383616477'] | [3064.0, 3064.0, 3064.0, 3060.0] | [17.0, 17.0, 17.0, 18.0] | [272, 272, 284, 176] |
p03030 | u605402887 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['#include<stdio.h>\n#include <string.h>\nint main(void){\n int n,i,j,x[10] = {1,2,3,4,5,6,7,8,9,10};\n scanf("%d",&n);\n char s[100][11],tmp_s[11];\n int d[100],tmp_d;\n for(i=0;i<n;++i){\n scanf("%s %d",&s[i],&d[i]);\n }\n for(i=0;i<n;++i){\n for(j=i+1;j<n;++j){\n if(strcm... | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s108871421', 's743935833', 's826335721'] | [2940.0, 2940.0, 2940.0] | [17.0, 17.0, 17.0] | [1137, 484, 163] |
p03030 | u605748139 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nall_point_list = [input().split() for _ in range(N)]\nfor each_list in all_point_list:\n each_list[1] = int(each_list[1])\nsorted_all_list = sorted(all_point_list)\nfor sorted_point in sorted_all_list:\n print(all_point_list.index(sorted_point)+1)', 'N = int(input())\nall_point_list = [input()... | ['Wrong Answer', 'Runtime Error', 'Accepted'] | ['s332639819', 's654514366', 's571948574'] | [3060.0, 3060.0, 3060.0] | [17.0, 17.0, 17.0] | [265, 265, 295] |
p03030 | u609061751 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N=int(input())\nSP=[]\nfor i in range(N):\n SP.append(input().split())\nfor j in range(N):\n SP[j].append(j)\nSP.sort(key=lambda x:x[1])\nSP.sort(key=lambda x:x[0])\nfor k in range(N):\n print(SP[k][2])', 'N=int(input())\nSP=[]\nfor i in range(N):\n SP.append(input().split())\nfor j in range(N):\n SP[j... | ['Wrong Answer', 'Accepted'] | ['s196136463', 's335105083'] | [3060.0, 3064.0] | [17.0, 18.0] | [202, 222] |
p03030 | u609814378 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['a', 'n=int(input())\nsp=[]\nfor i in range(n):\n s,p=input().split()\n sp.append([s,int(p),i+1])\nsp.sort(key=lambda sp:(sp[0],-sp[1]))\nfor i in sp:print(i[2])'] | ['Runtime Error', 'Accepted'] | ['s308153090', 's960223123'] | [2940.0, 3060.0] | [17.0, 17.0] | [1, 155] |
p03030 | u610473220 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\nl = []\nfor i in range(n):\n s, p = input().split()\n l.append((s,int(p),i))\nl.sort(key = lambda x:(x[0],x[1]), reverse = True)\nfor _ in l:\n print(l[2])', 'n = int(input())\nl = []\nfor i in range(n):\n s, p = input().split()\n l.append((s,int(p),i+1))\nl.sort(key = lambda x : x[1]... | ['Runtime Error', 'Accepted'] | ['s794510973', 's613760184'] | [3060.0, 3060.0] | [17.0, 17.0] | [175, 209] |
p03030 | u611090896 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\nL=[]\nfor i in range(n):\n s,p=input().split()\n L.append([s,int(p),i+1])\nlist.sort(L,reverse=True)\nfor i in range(n):\n print(L[i][2])\n', 'n = int(input())\nL=[]\nfor i in range(n):\n s,p=input()\n L.append([s,int(p),i+1])\nlist.sort(L,reverse=True)\nfor i in range(n):\n print(L[i][2])', '... | ['Wrong Answer', 'Runtime Error', 'Accepted'] | ['s449777726', 's736676257', 's074109953'] | [8964.0, 9092.0, 8904.0] | [26.0, 27.0, 27.0] | [152, 143, 140] |
p03030 | u617010143 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nSP = [list(input().split()) for i in range(N)]\n\nhoge = sorted(SP, key = lambda x:x[1], reverse = True)\nSPsort = sorted(hoge, key = lambda x:x[0]\n\nfor i in range(N):\n print(SP.index(SPsort[i]) + 1)', 'N = int(input())\nSP = [list(input().split()) for i in range(N)]\n\nSPsort = sorted(SP, key... | ['Runtime Error', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s321602262', 's425799638', 's639222663', 's803333702', 's422738273'] | [2940.0, 3060.0, 3060.0, 3060.0, 3060.0] | [17.0, 17.0, 17.0, 18.0, 18.0] | [216, 160, 160, 273, 258] |
p03030 | u617228707 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nA = []\nB = []\nfor i in range(N):\n n,a=input().split()\n A.append(n)\n B.append(int(a))\nfor i in range(N):\n c = i\n for k in range(i+1,N):\n if A[i] > A[k]:\n l = B[k]\n B[k] = B[i]\n B[i] = l\n l = A[k]\n A[k] = A[i]\n... | ['Wrong Answer', 'Accepted'] | ['s425212571', 's367259250'] | [3064.0, 3064.0] | [20.0, 21.0] | [591, 776] |
p03030 | u617556913 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['list = []\nN = int(input())\nfor i in range(N):\n S, P = map(str, input().split())\n list.append((i+1, S, int(P)))\nlist = sorted(lst, key=lambda x:(x[1], -x[2]))\n \nfor l in list:\n print(l[0])', 'list = []\nN = int(input())\nfor i in range(N):\n S, P = map(str, input().split())\n list.append((i+1, S, int(P)))... | ['Runtime Error', 'Accepted'] | ['s170212142', 's725798950'] | [9168.0, 8860.0] | [21.0, 26.0] | [190, 191] |
p03030 | u619785253 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ["from operator import itemgetter \ni = int(input())\n#print(i)\npoint =[]\nfor n in range(0,i):\n s, p = list(input().split(' '))\n point.append((s,int(p)))\n\npoint2 = sorted(point, key=itemgetter(1),reverse=True) \npoint3 = sorted(point2, key=itemgetter(0)) \n#print(point3)\n\nfor i in point:\n print(point3.inde... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s363404076', 's719667108', 's778001624'] | [3064.0, 3064.0, 3064.0] | [19.0, 19.0, 18.0] | [312, 311, 414] |
p03030 | u620846115 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = input()\nx = []\nfor i in range(n):\n s,p=input().split()\n x.append([s,int(p),i+1])\nx.sort(key=lambda x:(x[0],-x[1]))\nfor i in x:\n print(i[2])', 'n = int(input())\nx = []\nfor i in range(n):\n s,p=input().split()\n x.append([s,int(p),i+1])\nx.sort(key=lambda x:(x[0],-x[1]))\nfor i in x:\n print(i[2])'] | ['Runtime Error', 'Accepted'] | ['s649734823', 's371685426'] | [8988.0, 9116.0] | [21.0, 29.0] | [146, 151] |
p03030 | u621674426 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N=int(input())\nSlist=list()\nPlist=list()\ntmp=list()\nfor i in range(N):\n S,P=input().split()\n Slist.append(S)\n Plist.append(int(P))\n tmp.append(int(P))\nchange = True\nwhile change:\n change = False\n for i in range(len(Plist) - 1):\n if Plist[i] < Plist[i + 1]:\n Plist[i], ... | ['Wrong Answer', 'Accepted'] | ['s763540886', 's513008177'] | [3064.0, 3064.0] | [23.0, 22.0] | [811, 798] |
p03030 | u623231048 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\nli = []\n\nfor i in range(n):\n s,p = input().split()\n p = int(p)\n li.append([s,p,i])\n\nli.sort(key = lambda x:x[1],reverse = True)\nli.sort(key = lambda x:x[0])\n\nprint(li)\nfor i in range(n):\n print(li[i][2]+1)\n', 'n = int(input())\nli = []\n\nfor i in range(n):\n s,p = input(... | ['Wrong Answer', 'Accepted'] | ['s348120382', 's433502456'] | [3060.0, 3060.0] | [17.0, 18.0] | [235, 225] |
p03030 | u623245093 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['[print(i[2]) for i in sorted([[int(j) if j.isdecimal() else j for j in input().split()]+[i] for i in range(int(input()))], key=lambda x:x[1])]', '[print(i[2]+1) for i in sorted([[int(j) if j.isdecimal() else j for j in input().split()]+[i] for i in range(int(input()))], key=lambda x:x[1], reverse=True)]', '[print(i[2... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s738647971', 's917363569', 's225489262'] | [3060.0, 3060.0, 3060.0] | [18.0, 17.0, 17.0] | [142, 158, 185] |
p03030 | u623687794 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\nfrom operator import itemgetter\na=[]\nfor i in range(n):\n a.append(tuple(map(str,input().split()),i))\na1= sorted(a,key=itemgetter(0))\na2=sorted(a1,key=itemgetter(1),reverse=True)\nfor i in range(n):\n print(a2[i][2])', 'n = int(input())\nfrom operator import itemgetter\na=[]\nfor i in range(n)... | ['Runtime Error', 'Accepted'] | ['s890327191', 's515087859'] | [3060.0, 3064.0] | [18.0, 18.0] | [232, 254] |
p03030 | u625864724 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\ntbl = []\ns = []\np = []\nfor i in range(n):\n l = list(map(str,input().split()))\n l[1] = int(l[1])\n l2 = [l[1], l[0], i + 1]\n tbl.append(l2)\n s.append(l2[1])\n p.append(l2[0])\n\np.sort()\np.reverse()\ntbl2 = []\nfor i in range(n):\n for j in range(n):\n if(tbl[j][0]... | ['Wrong Answer', 'Accepted'] | ['s692171985', 's615309046'] | [9124.0, 8916.0] | [29.0, 29.0] | [480, 234] |
p03030 | u625963200 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['import numpy as np\n\nN = [int(i) for i in input().split()][0]\n\nls = []\nfor i in range(N):\n a,b = [i for i in input().split()]\n tmp = [str(a),int(b)]\n ls.append(tmp)\n\nnew_ls = sorted(ls, key=lambda x:x[1], reverse=True)\nnew_ls = sorted(ls, key=lambda x:x[0])\n\nfor next,l in enumerate(new_ls):\n for i,tm... | ['Wrong Answer', 'Accepted'] | ['s593059933', 's077750462'] | [12500.0, 3064.0] | [149.0, 19.0] | [393, 362] |
p03030 | u626337957 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nSP = [list(map(int, input().split())) for i in range(N)]\n\nsorted_SP = sorted(SP, key=lambda x:x[1], reverse=True)\nsorted_SP = sorted(sorted_SP, key=lambda x:x[0])\n\nfor i in range(N):\n for j in range(N):\n if SP[i][0] == sorted_SP[j][0] and SP[i][1] == sorted_SP[j][1]:\n print(j+1)\n ... | ['Runtime Error', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Accepted'] | ['s188930719', 's535771732', 's651899465', 's677293408', 's690248704', 's877955893'] | [3060.0, 2940.0, 3060.0, 3060.0, 3060.0, 3060.0] | [17.0, 17.0, 18.0, 18.0, 17.0, 19.0] | [318, 308, 312, 308, 304, 312] |
p03030 | u626881915 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\nshop_list = []\nfor i in range(n):\n s, p = input().split()\n shop_list.append((i+1, s, int(p)))\n\nshop_list = sorted(shop_list, key=lambda x:x[2], reverse=True)\nshop_list = sorted(shop_list, key=lambda x:(x[1], -x[2]), reverse=True)\nfor e in shop_list:\n print(e[0])', 'n = int(input())\nshop_... | ['Wrong Answer', 'Accepted'] | ['s602420806', 's828076535'] | [3060.0, 3060.0] | [19.0, 18.0] | [282, 205] |
p03030 | u627803856 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\n\na = []\n\nfor i in range(n):\n \t# input as str\n\ts, p = input().split()\n \n\tp = int(score)\n \n\ta.append((s, p, i+1))\n\n# sort\na.sort(key=lambda x:x[1], reverse=True)\n\n# sort\na.sort(key=lambda x:x[0])\n\n# output\nfor i in range(n):\n\tprint(a[i][2])', 'n = int(input())\n\na = []\... | ['Runtime Error', 'Accepted'] | ['s863374891', 's892050384'] | [3060.0, 3060.0] | [18.0, 18.0] | [289, 285] |
p03030 | u628581330 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\nres = []\nfor i in range(n):\n a,b = input().split()\n res.append ((a,b)) \nres_1 = sorted(res,key=lambda x: (x[0], -int(x[1])))\nfor i in range(len(res_1)):\n print(res.index(res_1[i]))', 'n = int(input())\nres = []\nfor i in range(n):\n a,b = input().split()\n res.append ((a,... | ['Wrong Answer', 'Accepted'] | ['s736221372', 's502090347'] | [3060.0, 3060.0] | [17.0, 17.0] | [213, 215] |
p03030 | u629350026 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n=int(input())\ntemp=[0]*n\nfor i in range(0,n):\n s,p=input().split()\n temp[i]=[i,s,int(p)]\ntemp=sorted(temp, key=lambda x: (x[1],-x[2]))\nfor i in range(0,n)\n print(temp[i])\n\n', 'n=int(input())\ntemp=[0]*n\nfor i in range(0,n):\n s,p=input().split()\n temp[i]=[i,s,int(p)]\ntemp=sorted(temp, key=lambda x: ... | ['Runtime Error', 'Wrong Answer', 'Accepted'] | ['s216708684', 's547138150', 's524420859'] | [2940.0, 3060.0, 3060.0] | [17.0, 17.0, 18.0] | [176, 177, 182] |
p03030 | u629538480 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ["N = int(input())\nsp_list = []\nsorted_list = []\nfor i in range(N):\n S,P = map(str, input().split(' '))\n sorted_list.append([S,P])\n sp_list.append(S + ' ' + P)\nsorted_list = sorted(sorted_list, key=lambda x:(x[1]), reverse=True)\nsorted_list = sorted(sorted_list, key=lambda x:(x[0]))\nfor i in range(N):\n co... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s773416555', 's892031808', 's501477678'] | [3064.0, 3064.0, 3064.0] | [19.0, 20.0, 20.0] | [442, 475, 456] |
p03030 | u629607744 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['def i():\n\treturn int(input())\ndef i2():\n\treturn map(int,input().split())\ndef s():\n\treturn str(input())\ndef l():\n\treturn list(input())\ndef intl():\n\treturn list(int(k) for k in input().split())\n\nn = i()\ns = {}\nfor i in range(n):\n\tS,P = map(str,input().split())\n\ts[i+1] = [S, -int(P)]\n\nnote = sort... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s413806473', 's489765535', 's668728235'] | [9136.0, 9260.0, 9112.0] | [30.0, 29.0, 29.0] | [382, 584, 572] |
p03030 | u633000076 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['a=int(input())\nc=[input().split(" ")for i in range(0,a)]\nfor i in c:\n i[1]=int(i[1])\n#print(c)\nd=sorted(c,key=lambda x:(x[0],-x[1]))\n#print(d)\nfor i in c:\n print(d.index(i)+1)', 'a=int(input())\nc=[input().split(" ")for i in range(0,a)]\nfor i in c:\n i[1]=int(i[1])\n#print(c)\nd=sorted(c,key=lambda ... | ['Wrong Answer', 'Accepted'] | ['s640518378', 's877334028'] | [3060.0, 3060.0] | [18.0, 17.0] | [181, 181] |
p03030 | u634173914 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nassign = []\nfor index in range(1,N+1):\n S, P = map(str, input().split())\n P = int(P)\n assign.append([S, P, index])\n\nassign = sorted(assign, key=lambda x:(x[0], -x[1]))\nprint(assign)', 'N = int(input())\nassign = []\nfor index in range(1,N+1):\n S, P = map(str, input().split())\n ... | ['Wrong Answer', 'Accepted'] | ['s321523505', 's505704369'] | [3060.0, 3060.0] | [17.0, 17.0] | [207, 238] |
p03030 | u635974378 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\ncity_score = {}\nfor i in range(n):\n\tcity, score = input.split()\n city_score[city] = city_score.get(city, []). + [(int(score), i)]\n\nfor city in sorted(city_score.keys()):\n for score in sorted(city_score[city]):\n print(score[1])', 'n = int(input())\ncity_score = {}\nfor i in range(n):\n... | ['Runtime Error', 'Accepted'] | ['s967626775', 's867738813'] | [2940.0, 3060.0] | [17.0, 18.0] | [250, 271] |
p03030 | u638456847 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N=int(input())\n\nname=[input().split() for i in range(N)]\nscore=[]\n\nprint(name)\n\nname2=sorted(name,key=lambda x:(x[0],-int(x[1])))\n\nprint(name2)\n\nfor i in range(N):\n for j,city in enumerate(name):\n if name2[i]==city:\n print(j+1)', 'N=int(input())\n\nname=[input().split() for i in ran... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s299220200', 's622634098', 's420631295'] | [3060.0, 3060.0, 3060.0] | [19.0, 19.0, 18.0] | [298, 300, 300] |
p03030 | u640603056 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\nlst=[]\nfor i in range(1, n+1):\n s, p = input().split()\n p = int(p) * -1\n lst.append([s, p, i])\nlst = sorted(lst)\nprint(lst)\nfor i in range(n):\n print(lst[i][2])', 'n = int(input())\nlst=[]\nfor i in range(1, n+1):\n s, p = input().split()\n p = int(p) * -1\n lst.append([... | ['Wrong Answer', 'Accepted'] | ['s849372195', 's745206491'] | [3060.0, 3060.0] | [17.0, 17.0] | [189, 178] |
p03030 | u641460756 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\nf = []\ns = []\np = []\nfor i in range(n):\n f += [list(map(str, input().split(" ")))]\n s += [f[i][0]]\n p += [int(f[i][1])]\nprint(p)\ns.sort()\np.sort(reverse=True)\nprint(p)\nans = [0] * n\ncount = 0\nfor i in s:\n for j in p:\n if [i, str(j)] in f:\n ans[count] = f... | ['Runtime Error', 'Accepted'] | ['s192394208', 's890454268'] | [3064.0, 3060.0] | [51.0, 18.0] | [446, 243] |
p03030 | u646110634 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['from operator import itemgetter\nN = int(input())\nrest = []\n\nfor i in range(N) :\n raw = list(input().split())\n raw[1] = int(raw[1]) \n raw.append(int(i + 1))\n rest.append(raw)\n\nrest.sort(key=itemgetter(0, 1))\n\nfor k in range(N) :\n print(rest[k][2])', 'from operator import itemgetter\nN = int(input())\... | ['Wrong Answer', 'Accepted'] | ['s234821748', 's626011745'] | [3060.0, 3060.0] | [18.0, 18.0] | [251, 294] |
p03030 | u648212584 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\n\nmylist = []\nfor i in range(n):\n\tmylist.append(list(map(str,input().split())))\n\tmylist[i].append(i+1)\n\nmylist = sorted(mylist,key=lambda mylist:(mylist[0],-int(mylist[1])))\nfor i in mylist:\n\tprint(i[2])', 'n = int(input())\n\nmylist = []\nfor i in range(n):\n\tmylist.append(list(map(str,i... | ['Runtime Error', 'Accepted'] | ['s674983267', 's153873585'] | [3060.0, 3060.0] | [18.0, 18.0] | [219, 220] |
p03030 | u648881683 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ["import sys\ninput = lambda: sys.stdin.readline().rstrip() \n\ndef resolve():\n N = int(input())\n SP = [input().split() for _ in range(N)]\n\n SP = enumerate(SP)\n SP = sorted(SP, key=lambda x: (x[1][1], -x[1][0]))\n for i in SP:\n print(i[0]) \n\nif __name__ == '__main__':\n resolve()\n",... | ['Runtime Error', 'Accepted'] | ['s548960118', 's574781419'] | [3060.0, 3060.0] | [18.0, 17.0] | [302, 309] |
p03030 | u652150585 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ["n=int(input())\nl=[[i+1] for i in range(n)]\nfor i in range(n):\n l[i]+=list(input().split(' '))\nprint(l)\nl.sort(key=lambda x:x[2],reverse=True)\nl.sort(key=lambda x:x[1])\nfor i in range(n):\n print(l[i][0])", "n=int(input())\nl=[[i+1] for i in range(n)]\nfor i in range(n):\n l[i]+=list(input().split(' ')... | ['Wrong Answer', 'Accepted'] | ['s450172250', 's405404915'] | [3060.0, 3064.0] | [18.0, 18.0] | [208, 234] |
p03030 | u653837719 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\nsp = []\nfor i in range(n):\n s, p = map(str, input().split())\n sp.append([s, int(p), i + 1])\n\nsp.sort(key = lambda x:(x[0], x[1]))\n\nfor e in sp:\n print(e[2])', 'n = int(input())\nsp = []\nfor i in range(n):\n s, p = map(str, input().split())\n sp.append([s, int(p), i + 1])\n\ns... | ['Wrong Answer', 'Accepted'] | ['s496708779', 's169475326'] | [3060.0, 3064.0] | [18.0, 18.0] | [182, 219] |
p03030 | u654470292 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n=int(input())\nli=[0]*n\nfor i in range(n):\n a=input().split()\n li[i]=[a[0], -int(a[1]), i+1]\n\nli.sort(key=lambda x:(x[0],int(x[1])))\nprint(li)\nfor i in li:\n print(i[2])', 'n=int(input())\nli=[0]*n\nfor i in range(n):\n a=input().split()\n li[i]=[a[0], -int(a[1]), i+1]\n\nli.sort(key=lambda x:(... | ['Wrong Answer', 'Accepted'] | ['s438142153', 's740511459'] | [3064.0, 3060.0] | [18.0, 18.0] | [177, 168] |
p03030 | u655110382 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['def make_guide():\n num = int(input())\n lst = [(i + 1, input().split()) for i in range(num)]\n lst = sorted(sorted(lst, key=lambda t: t[1][1]), key=lambda t: t[1][0])\n return lst\n\n\ndef test_display():\n lst = make_guide()\n for i, lst in lst:\n print(str(i) + " " + lst[0] + " " + lst[1])... | ['Wrong Answer', 'Runtime Error', 'Runtime Error', 'Accepted'] | ['s408727673', 's418464942', 's809449541', 's078971475'] | [3064.0, 2940.0, 2940.0, 3064.0] | [18.0, 17.0, 17.0, 18.0] | [434, 439, 250, 605] |
p03030 | u657901243 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nX = []\nfor i in range(N):\n\ts, p = input().split()\n\tX.append([s, -int(p), i+1])\nX.sort()\nfor i in range(N):\n\tprint(-X[i][1])', 'N = int(input())\nX = []\nfor i in range(N):\n\ts, p = input()\n\tX.append([s, p, i+1])\nX.sort()\ns = X[0][0]\nfor i in range(N):\n\tj = i\n\twhile True:\n\t\tif... | ['Wrong Answer', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Accepted'] | ['s294739796', 's513208868', 's746518536', 's831669535', 's977906834', 's270460520'] | [3060.0, 2940.0, 2940.0, 3060.0, 3060.0, 3060.0] | [17.0, 17.0, 17.0, 17.0, 17.0, 18.0] | [141, 275, 133, 261, 141, 140] |
p03030 | u658987783 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N=int(input())\nS={}\n\nfor i in range(N):\n p,q=input().split()\n S[i+1]=(p,int(q))\nS=sorted(S,key=lambda x:(S[x][0],-S[x][1]))\nprint(S)\n\nprint(*S,sep="\\n")', 'N=int(input())\nS={}\n\nfor i in range(N):\n p,q=input().split()\n S[i+1]=(p,int(q))\nS=sorted(S,key=lambda x:(S[x][0],-S[x][1]))\n\nprint(*S,sep="\... | ['Wrong Answer', 'Accepted'] | ['s757792390', 's880919873'] | [3060.0, 3064.0] | [17.0, 17.0] | [154, 145] |
p03030 | u659563289 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['def main():\n n = int(input())\n store = []\n for i in range(n):\n s, p = input().split()\n \n store.append((i, s, int(p)))\n\n store.sort(key=lambda x:(x[1],x[2]))\n for i in range(n):\n print(store[i][0])\n\n\nif __name__ == "__main__":\n main()\n', 'def main():\n n ... | ['Wrong Answer', 'Accepted'] | ['s503343634', 's384284132'] | [3060.0, 3060.0] | [18.0, 17.0] | [307, 379] |
p03030 | u660750079 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N=int(input())\nbook1={}\nfor i in range(1,N+1):\n string,point=input().split()\n point=int(point)\n if string in book1.keys():\n book1[string][point]=i\n else:\n book1[string]={point:i}\nfor keys in sorted(book1.keys()):\n for point in reversed(list(book1[keys].keys())):\n print(... | ['Wrong Answer', 'Accepted'] | ['s732881933', 's113278634'] | [3060.0, 3060.0] | [17.0, 17.0] | [326, 331] |
p03030 | u662449766 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['import sys\n\ninput = sys.stdin.readline\n\n\ndef main():\n n = int(input())\n s = [[int(i) if i.isdigit() else i for i in input().split()] for _ in range(n)]\n rank = {\n tuple(review): i\n for i, review in enumerate(\n sorted(sorted(s, key=lambda x: x[1], reverse=True), key=lambda ... | ['Wrong Answer', 'Accepted'] | ['s059842281', 's081758110'] | [3060.0, 3060.0] | [18.0, 17.0] | [440, 281] |
p03030 | u663561584 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nS = []\n\nfor i in range(N):\n ts,tp = input().split()\n ts = str(ts)\n tp = int(tp)\n S.append([ts,tp])\n\nS.sort(key=lambda x:x[0])\n\nfor i in range(N):\n print(S[i][0])', 'N = int(input())\nS = []\n \nfor i in range(N):\n ts,tp = input().split()\n ts = str(ts)\n tp = int(... | ['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s247646296', 's656230072', 's682841086', 's216678151'] | [3060.0, 3064.0, 3060.0, 3060.0] | [17.0, 18.0, 17.0, 18.0] | [193, 202, 197, 213] |
p03030 | u664373116 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['#from operater import itemgetter\nfrom collections import Counter\nimport numpy as np\nN=int(input())\nc=[]\nv=[]\nans=[]\nc_v={}\nfor i in range(N):\n tmp=input().split()\n ans.append(tmp)\n c.append(tmp[0])\n v.append(int(tmp[1]))\n if tmp[0] in c_v.keys():\n c_v[tmp[0]].append(int(tmp[1]))\n ... | ['Wrong Answer', 'Accepted'] | ['s856732783', 's954198248'] | [12492.0, 3316.0] | [154.0, 21.0] | [704, 490] |
p03030 | u669787859 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ["# -*- coding; utf 8 -*-\n# Guidebook\n# 2019. 5/28\n\n\n\n\n\nclass Guidebook(object):\n def __init__(self, num, city, score):\n self.num = num\n self.city = city\n self.score = score\n\n\ndef print_number(N, guidebook):\n for i in range(N):\n print(guidebook[i].num+1)\n\n\ndef score... | ['Wrong Answer', 'Accepted'] | ['s072006062', 's242911709'] | [3064.0, 3064.0] | [24.0, 23.0] | [1218, 1216] |
p03030 | u670567845 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nranking = []\nfor i in range(N):\n si, pi = input().split()\n ranking.append((si,int(pi),i))\n \nprint(ranking)', 'N = int(input())\nD = [list(map(str,input().split())) for _ in range(N)]\nfor i in range(N):\n D[i].append(i+1)\nsorted_d = sorted(D, key = lambda x: (x[0], -int(x[1])))\nfor i in r... | ['Wrong Answer', 'Accepted'] | ['s454242504', 's421242181'] | [2940.0, 9116.0] | [17.0, 23.0] | [126, 209] |
p03030 | u671211357 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['from operator import itemgetter\nN=int(input())\nhako=[]\nfor i in range(N):\n A,B=input().split()\n hako.append([A,int(B)*-1])\nkari=hako.copy()\n#print(kari)\nhako.sort()\nhako=sorted(hako,key=itemgetter(0,1))\n#print(hako)\nfor i in range(N):\n print(hako.index(kari[i])+1)', 'from operator import itemgett... | ['Wrong Answer', 'Accepted'] | ['s983660536', 's241122013'] | [3060.0, 3060.0] | [18.0, 18.0] | [273, 236] |
p03030 | u677121387 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\ns_p = [[i+1]+input().split() for i in range(n)]\n\ns_p.sort(key=lambda x:x[1]+str(100-int(x[2])))\n\nprint([x[0] for x in s_p])', 'n = int(input())\ns_p = [[i+1]+input().split() for i in range(n)]\n\ns_p.sort(key=lambda x:x[1]+str(100-int(x[2])))\n\nprint([(x[0]) for x in s_p])', 'n = int(input())\n... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s172267176', 's276407805', 's466835287'] | [3060.0, 3060.0, 3060.0] | [18.0, 17.0, 18.0] | [140, 142, 135] |
p03030 | u679325651 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nSPlist = []\nfor i in range(N):\n buff = input().split()\n SPlist.append([i+1,str(buff[0]),int(buff[1])])\nprint(SPlist)\nSPlist = sorted(SPlist,key = lambda x:x[2],reverse=True)\nSPlist = sorted(SPlist,key=lambda x:x[1])\n[print(i[0]) for i in SPlist]', 'N = int(input())\nSPlist = []\nfor i ... | ['Wrong Answer', 'Accepted'] | ['s754960294', 's649869590'] | [3064.0, 3064.0] | [18.0, 18.0] | [269, 255] |
p03030 | u679439110 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\nl = []\nfor i in range(n):\n\ts, p = input().split()\n\tp = int(p)\n\tl.append([s, p, i+1])\n\nl = sorted(l, key=lambda x:x[1])\nl = sorted(l)\n\nfor e in l:\n\tprint(e[2])', 'n = int(input())\nl = []\nfor i in range(n):\n\ts, p = input().split()\n\tp = int(p)\n\tl.append([s, p, i+1])\n\nl.sort(key=... | ['Wrong Answer', 'Accepted'] | ['s165707294', 's644764630'] | [3060.0, 3060.0] | [17.0, 17.0] | [175, 194] |
p03030 | u682408064 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ["# input\nN = int(input())\nSA = [str(input()) for i in range(N)]\n\n# process\ncities = list(set([x.split()[0] for x in SA]))\ncities.sort()\nprint(cities)\n\nfor y in cities:\n each_SA = [i for i in SA if y in i]\n each_points = [int(x.split()[1]) for x in each_SA]\n each_points.sort(reverse=True)\n for ... | ['Runtime Error', 'Accepted'] | ['s868957399', 's941338703'] | [3060.0, 3060.0] | [17.0, 19.0] | [369, 409] |
p03030 | u686036872 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nlist=[]\nfor i in range(N):\n s, p = input().split()\n list.append([s, int(p)])\nlis=sorted(key=lambda, list:(list[0], -list[1]))\nfor i in list:\n print(lis.index(i)+1)', 'N = int(input())\nlist=[]\nfor i in range(N):\n s, p = input().split()\n list.append([s, int(p)])\nA=list\nlist.... | ['Runtime Error', 'Runtime Error', 'Wrong Answer', 'Accepted'] | ['s720496245', 's890098465', 's930875011', 's628949339'] | [2940.0, 2940.0, 3060.0, 3064.0] | [17.0, 17.0, 18.0, 17.0] | [189, 193, 197, 182] |
p03030 | u686989171 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n=int(input())\nsp=[]\nfor i in range(n):\n x,y=input().split()\n sp.append([x,int(y),i+1])\n sp.sort(key=lambda x:(x[0],x[1]))\nfor i in range(n):\n print(sp[i][2])', 'n=int(input())\nsp=[]\nfor i in range(n):\n x,y=input().split()\n sp.append([x,int(y),i+1])\n sp.sort(key=lambda x:(x[0],-x[1]))\nfor i in ran... | ['Wrong Answer', 'Accepted'] | ['s914696892', 's515074745'] | [3060.0, 3060.0] | [19.0, 19.0] | [162, 163] |
p03030 | u692453235 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nL = []\n\nfor i in range(N):\n S, P = input().split()\n L.append([S, int(P), i+1])\n\nLS = sorted(L)\n\nfor i in range(N):\n print(LS[i][2])', 'N = int(input())\nL = []\n\nfor i in range(N):\n S, P = input().split()\n L.append([S, (-1)*int(P), i+1])\n\nLS = sorted(L)\n\nfor i in range(N):\n pr... | ['Wrong Answer', 'Accepted'] | ['s105139988', 's171332038'] | [3064.0, 3060.0] | [18.0, 17.0] | [151, 156] |
p03030 | u694665829 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n=int(input())\nR=[list(input().split()) + [i+1] for i in range(n)]\nR.sort(key=lambda x: (x[0],-int(x[1])))\nprint(R)\nfor r in R:\n print(r[2])', 'n=int(input())\nR=[list(input().split()) + [i+1] for i in range(n)]\nR.sort(key=lambda x: (x[0],-int(x[1])))\nfor r in R:\n print(r[2])'] | ['Wrong Answer', 'Accepted'] | ['s642611528', 's098795448'] | [9084.0, 9060.0] | [26.0, 27.0] | [143, 134] |
p03030 | u694810977 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nlists_S = []\nlists_P = []\nfor i in range(N):\n S,P = map(str,str(input()).split())\n lists_S.append(S)\n lists_P.append(int(P))\nc = list(zip(lists_S,lists_P))\nc = sorted(c,key=lambda x:(x[0],-x[1]))\ns,p = zip(*c)\nprint(s,p)\nlists_index = []\nfor i in range(N):\n for j in range(N):... | ['Wrong Answer', 'Accepted'] | ['s726212713', 's969707807'] | [3064.0, 3064.0] | [20.0, 21.0] | [484, 463] |
p03030 | u698176039 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nSP = [list(map(str,input().split())) + [i+1] for i in range(N)]\n\nSP.sort(key = lambda x:x[0])\nidx = 0\ninit = SP[idx][0]\nwhile idx < N:\n D = []\n while idx < N and SP[idx][0] == init:\n D += [SP[idx]]\n idx += 1\n D.sort(reverse = True,key = lambda x:int(x[1]))\n for ... | ['Wrong Answer', 'Accepted'] | ['s305956575', 's222411257'] | [3064.0, 3188.0] | [18.0, 20.0] | [412, 399] |
p03030 | u698868214 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\n\nSP = []\nfor _ in range(N):\n S,P = input().split()\n SP.append([S,-int(P)])\n \nsort_SP = sorted(SP)\n\nfor i in SP:\n print(sort_SP.index(i)+1)', 'N = int(input())\n\nSP = []\nfor i in range(1,N+1):\n S,P = input().split()\n SP.append([S,-int(P),i])\n \nsort_SP = sorted(SP)\n\nfor j in so... | ['Wrong Answer', 'Accepted'] | ['s293794103', 's776602292'] | [9180.0, 8976.0] | [30.0, 26.0] | [159, 156] |
p03030 | u700636661 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['import sys\n\ndef main():\n num = int(sys.stdin.readline())\n \n input = [None] * num\n\n for i in range(num):\n read = sys.stdin.readline().split()\n input[i] = [i+1, read[0], int(read[1])]\n\n input.sort(key=lambda x:(x[1], x[2]))\n\n for restaurant in input:\n print(restauran... | ['Wrong Answer', 'Wrong Answer', 'Accepted'] | ['s407913263', 's895163919', 's402372422'] | [3060.0, 3060.0, 3060.0] | [17.0, 17.0, 17.0] | [349, 347, 350] |
p03030 | u706828591 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['#n, x = map(int,input().split())\nn = int(input())\nls = [["",[[]]]]\nfor i in range(n):\n s, p = input().split()\n p = int(p)\n for j in ls:\n if s == j[0]:\n j[1].append([i+1,p])\n break\n elif j == ls[-1]:\n ls.append([s,[[i+1,p]]])\n break\n#ls = list(map(int,input().split()))\n#s = i... | ['Wrong Answer', 'Accepted'] | ['s362916552', 's333497280'] | [3064.0, 3064.0] | [18.0, 19.0] | [439, 426] |
p03030 | u713728708 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n=int(input())\ncityLst=[]\nfor i in range(n):\n\ts,p=map(str,input().split(" "))\n\tcityLst.append(["{:<10}".format(s),p])\nsCityLst=sorted(cityLst,key=lambda x:x[0]+"a"+chr(int(x[1])+97))\nfor o in sCityLst:\n\tprint(cityLst.index(o)+1)', 'n=int(input())\ncityLst=[]\nfor i in range(n):\n\ts,p=map(str,input().split(... | ['Wrong Answer', 'Accepted'] | ['s255817961', 's349168067'] | [3060.0, 3060.0] | [18.0, 18.0] | [228, 237] |
p03030 | u713830790 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\n\ntable = []\nfor i in range(n):\n city, score = input().split()\n score = int(score)\n\n table.append([i+1, city, score])\n\nsorted_table = sorted(table, key=lambda x:(x[1], -x[2]))\n\nprint(sorted_table)\nfor i in range(n):\n print(sorted_table[i][0])', 'n = int(input())\n\ntable = []\nfor i... | ['Wrong Answer', 'Accepted'] | ['s505157113', 's759421503'] | [3060.0, 3060.0] | [17.0, 17.0] | [263, 244] |
p03030 | u713914478 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['a = []\n\nfor i in range(N):\n\tS,P = input().split()\n\tP = int(P)\n\ta.append([S,-P,i])\n\na.sort()\nfor aa in a:\n\tprint(aa[2])', 'N = int(input())\na = []\n\nfor i in range(N):\n\tS,P = input().split()\n\tP = int(P)\n\ta.append([S,-P,i])\n\na.sort()\nfor aa in a:\n\tprint(aa[2]+1)'] | ['Runtime Error', 'Accepted'] | ['s012894198', 's270223893'] | [2940.0, 3060.0] | [17.0, 18.0] | [118, 137] |
p03030 | u721425712 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['# B\n# 2020/3/9 17:57-\nn = int(input())\nl = []\nfor i in range(n):\n ss, pp = map(str, input().split())\n l.append([ss, int(pp), i])\n \nl.sort()\nfor v in l:\n print(v[2]+1)', '# B\n# 2020/3/9 17:57-\nn = int(input())\nl = []\nfor i in range(n):\n ss, pp = map(str, input().split())\n l.append([... | ['Wrong Answer', 'Accepted'] | ['s983186317', 's773660854'] | [3060.0, 3060.0] | [18.0, 17.0] | [179, 239] |
p03030 | u723583932 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['#128 b\nn=int(input())\nres=[]\nfor i in range(n):\n a,b=list(input().split())\n b=-1*int(b)\n res.append([a,b,i+1])\nres=sorted(res)\nfor i in n:\n print(x[2])\n', '#128 b\nn=int(input())\nres=[]\nfor i in range(n):\n a,b=list(input().split())\n b=-1*int(b)\n res.append([a,b,i+1])\nres=sorted(re... | ['Runtime Error', 'Accepted'] | ['s025541375', 's707627764'] | [2940.0, 3060.0] | [17.0, 21.0] | [164, 165] |
p03030 | u727025296 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['from operator import itemgetter\n\ncity_point_list = []\nN = int(input())\nfor i in range(N):\n c, p = input().split()\n city_point_list.append(c, int(p))\n\ncp_num_dict = {}\nfor i in range(city_point_list):\n cp_num_dict[city_point_list[i]] = i + 1\n\npoint_sort_rev = sorted(city_point_list, key=itemgetter... | ['Runtime Error', 'Accepted'] | ['s428707098', 's512868503'] | [3064.0, 3188.0] | [18.0, 18.0] | [428, 452] |
p03030 | u727608386 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['import numpy as np\nfrom nltk.classify.maxent import calculate_empirical_fcount\nN = int(input())\nSList = []\nPList = []\ndic = {}\nSlist = []\naa = []\nfor _ in range(N):\n S, P = input().split()\n dic[S] = int(P)\n Slist.append(S)\n aa.append((int(P), S))\ndic = sorted(dic.items())\n\nsortedS = list(so... | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s209712354', 's570672278', 's265205801'] | [12500.0, 12472.0, 12504.0] | [148.0, 154.0, 154.0] | [599, 598, 538] |
p03030 | u728274111 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\nlist = []\nfor xi in range(n):\n add1, add2 = input().split()\n add = [add2, add1, xi+1]\n list.append(add)\nlist.sort(key=lambda list2: list2[1])\n\nprint(list)\n\nname = list[0][1]\nlist2 = [list[0]]\ncount = 1\nfor xi in range(1,n):\n if name == list[xi][1]:\n list2.append(list... | ['Runtime Error', 'Runtime Error', 'Accepted'] | ['s130716815', 's412648164', 's523507556'] | [9192.0, 9196.0, 9248.0] | [28.0, 23.0, 27.0] | [684, 672, 635] |
p03030 | u729300713 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['N = int(input())\nS=[0]*N\nP=[0]*N \nfor i in range(N):\n S[i], P[i] = input().split()\n P[i] = int(P[i])\n\nS_mid = sorted(S, key=lambda x:P[x])\nS_fin = sorted(range(len(S_mid)), key=lambda idx:S_mid[idx])\n\nfor i in fin:\n print (i)', 'N = int(input())\nsp=[[0]*3 for i in range(N)]\nfor i in range(N):\n ... | ['Runtime Error', 'Wrong Answer', 'Runtime Error', 'Wrong Answer', 'Runtime Error', 'Accepted'] | ['s434025366', 's437520439', 's533152802', 's568935218', 's973345318', 's709966426'] | [3064.0, 3064.0, 3064.0, 3060.0, 2940.0, 3064.0] | [18.0, 18.0, 17.0, 17.0, 18.0, 17.0] | [286, 253, 251, 253, 226, 269] |
p03030 | u731368968 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['a=[]\nfor i in range(int(input())):\n s, p = input().split()\n p=int(p)\n a.append((s,p,i+1))\na.sort(key=lambda x:(x[0],-x[1]))\nprint(a)\n[print(x[2])for x in a]', 'a=[]\nfor i in range(int(input())):\n s, p = input().split()\n p=int(p)\n a.append((s,p,i+1))\na.sort(key=lambda x:(x[0],-x[1]))\n[pr... | ['Wrong Answer', 'Accepted'] | ['s849092020', 's610817297'] | [3060.0, 3060.0] | [17.0, 17.0] | [165, 156] |
p03030 | u733608212 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\n\nli = []\nfor i in range(n):\n li.append(list(map(str, input().split())))\n li[i].append(i+1)\n\nli.sort( key = lambda li : (li[0], -int(li[1])))\nprint(li)\n', 'n = int(input())\n\nli = []\nfor i in range(n):\n li.append(list(map(str, input().split())))\n li[i].append(i+1)\n\nli.sort( ... | ['Wrong Answer', 'Runtime Error', 'Accepted'] | ['s381940719', 's520727981', 's808257880'] | [3060.0, 3060.0, 3060.0] | [18.0, 18.0, 18.0] | [174, 194, 193] |
p03030 | u738816250 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['import numpy as np\nfrom operator import itemgetter\n \nN = int(input())\n \nlist = []\nfor i in range(N):\n a,b=input().split()\n list.append([a, int(b),i+1])\nsort1 = sorted(list, key=itemgetter(0))\nif N == 1:\n \tprint(1)\nelse:\n ans = []\n kari = []\n end = 1\n k = 1\n for i in range(0,N-1... | ['Wrong Answer', 'Runtime Error', 'Accepted'] | ['s111018895', 's562925690', 's863189263'] | [12612.0, 2940.0, 12500.0] | [149.0, 17.0, 150.0] | [892, 866, 863] |
p03030 | u740767776 | 2,000 | 1,048,576 | You have decided to write a book introducing good restaurants. There are N restaurants that you want to introduce: Restaurant 1, Restaurant 2, ..., Restaurant N. Restaurant i is in city S_i, and your assessment score of that restaurant on a 100-point scale is P_i. No two restaurants have the same score. You want to in... | ['n = int(input())\ns = []\nfor i in range(n):\n name,point = input().split()\n s.append([name,int(point)])\nfor i in range(n):\n rank = 1\n for j in range(n):\n if s[i][0] > s[j][0]:\n rank += 1\n elif s[i][0] == s[j][0] and s[i][1] < s[j][1]:\n rank += 1\n print(... | ['Wrong Answer', 'Accepted'] | ['s452937959', 's310150074'] | [3060.0, 3060.0] | [21.0, 19.0] | [312, 161] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.