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
|
---|---|---|---|---|---|---|---|---|---|---|
p02688
|
u164108868
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k=map(int,input().split())\nm=[]\nfor _ in range(2*k):\n d=int(input())\n a=list(map(int,input().split()))\n for i in a:\n if i not in m:\n m.append(i)\nmx=max(m)\nc=0\nfor i in range(1,n+1):\n if(i not in m):\n c+=1\nprint(c) ', 'n,k=map(int,input().split())\nm=[]\nfor _ in range(k):\n d=int(input())\n a=list(map(int,input().split()))\n for i in a:\n if i not in m:\n m.append(i)\nmx=max(m)\nc=0\nfor i in range(1,n+1):\n if(i not in m):\n c+=1\nprint(c) ']
|
['Runtime Error', 'Accepted']
|
['s846068311', 's225178275']
|
[9220.0, 9184.0]
|
[27.0, 25.0]
|
[234, 232]
|
p02688
|
u164471280
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n, k = map(int, input().split())\nA = []\nfor i in range(k):\n d = int(input())\n A.extend(list(map(int, input().split())))\n\nN = [] \nfor i in range(1, n+1):\n N.append(i)\nprint(A,N)\nprint(len(set(A)^set(N)))', 'n, k = map(int, input().split())\nA = []\nfor i in range(k):\n d = int(input())\n A.extend(list(map(int, input().split())))\n\nN = [] \nfor i in range(1, n+1):\n N.append(i)\n# print(A,N)\nprint(len(set(A)^set(N)))']
|
['Wrong Answer', 'Accepted']
|
['s803191903', 's497119027']
|
[9192.0, 9184.0]
|
[22.0, 21.0]
|
[214, 216]
|
p02688
|
u189485655
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k = map(int,input().split())\n\nl=[0]*n\n\nprint(l)\n\nfor i in range(k):\n d=int(input())\n a=list(map(int,input().split()))\n for j in a:\n l[j-1]+=1\n\nprint(l.count(0))\n', 'n,k = map(int,input().split())\n\nl=[0]*n\n\nfor i in range(k):\n d=int(input())\n a=list(map(int,input().split()))\n for j in a:\n l[j-1]+=1\n\nprint(l.count(0))\n']
|
['Wrong Answer', 'Accepted']
|
['s503021009', 's710925872']
|
[9172.0, 9172.0]
|
[20.0, 22.0]
|
[179, 169]
|
p02688
|
u190905976
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N,K = map(int,input().split())\nN = set([int(i) for i in range(1,N+1)])\nfor k in range(K):\n d = int(input())\n A = [int(i) for i in input().split()]\n a = set(A)\n N = N-a\n\nfor n in N:\n print(n)', 'N,K = map(int,input().split())\nN = set([int(i) for i in range(1,N+1)])\nfor k in range(K):\n d = int(input())\n A = [int(i) for i in input().split()]\n a = set(A)\n N = N-a\nprint(len(N))']
|
['Wrong Answer', 'Accepted']
|
['s453997630', 's897551670']
|
[9160.0, 9012.0]
|
[23.0, 21.0]
|
[205, 193]
|
p02688
|
u195396655
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N, K = map(int, input().split())\n\nlst = [0] * N\n\nfor i in range(K):\n\td = input()\n A = list(map(int, input().split()))\n for a in A:\n \tlst[a-1] += 1\n\nprint(lst.count(0)) ', 'N, K = map(int, input().split())\n\nlst = [0] * N\n\nfor i in range(K):\n\td = input()\n\tA = list(map(int, input().split()))\n\tfor a in A:\n\t\tlst[a-1] += 1\n\nprint(lst.count(0))']
|
['Runtime Error', 'Accepted']
|
['s167662855', 's595846782']
|
[8808.0, 9096.0]
|
[21.0, 21.0]
|
[184, 167]
|
p02688
|
u199941968
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N,K=map(int,input().split())\narr=[]\nans=[str(i) for i in range(1,N+1)]\nfor i in range(K):\n _=input()\n arr.extend((input().split()))\n arr=list(set(arr))\np=0\n\nfor n in ans:\n if(n in arr) :\n p=p+1\nprint(p)\n\n\n', 'N,K=map(int,input().split())\narr=[]\nans=[str(i) for i in range(1,N+1)]\nfor i in range(K):\n _=input()\n arr.extend((input().split()))\n arr=list(set(arr))\np=0\nfor n in ans:\n if(!(n in arr) ) :\n p=p+1\nprint(p)\n\n\n', 'N,K=map(int,input().split())\narr=[]\nans=[str(i) for i in range(1,N+1)]\nfor i in range(K):\n _=input()\n arr.extend((input().split()))\n arr=list(set(arr))\np=0\nfor n in ans:\n if(not(n in arr) ) :\n p=p+1\nprint(p)\n\n\n']
|
['Wrong Answer', 'Runtime Error', 'Accepted']
|
['s293839292', 's800990436', 's494865611']
|
[9176.0, 8932.0, 9068.0]
|
[21.0, 19.0, 24.0]
|
[229, 230, 232]
|
p02688
|
u201986772
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['import numpy as np\nN, K = map(int, input().split())\nN_lis=np.zeros(N)\nfor i in range(K):\n d=int(input())\n sweet=np.arrray(map(int, input().split()))\n sweet-=1\n for j in sweet:\n N_lis[j]+=1\n\nno_sweet=N_lis[N_lis==0]\nprint(no_sweet.sum())\n\n\n ', 'import numpy as np\nN, K = map(int, input().split())\nN_lis=np.zeros(N)\nfor i in range(K):\n d=int(input())\n sweet=np.array(map(int, input().split()))\n sweet-=1\n for j in sweet:\n N_lis[j]+=1\n \nno_sweet=N_lis[N_lis==0]\nprint(no_sweet.sum())', 'import numpy as np\nN, K = map(int, input().split())\nN_lis=np.zeros(N)\nfor i in range(K):\n d=int(input())\n sweet=np.array(list(map(int, input().split())))\n #print(sweet)\n sweet-=1\n for j in sweet:\n N_lis[j]+=1\nprint(N_lis)\nno_sweet=N_lis==0\nprint(no_sweet)\nprint(no_sweet.sum()))', 'import numpy as np\nN, K = map(int, input().split())\nN_lis=np.zeros(N)\nfor i in range(K):\n d=int(input())\n sweet=np.array(list(map(int, input().split())))\n #print(sweet)\n sweet-=1\n for j in sweet:\n N_lis[j]+=1\nprint(N_lis)\nno_sweet=N_lis==0\nprint(no_sweet)\nprint(no_sweet.sum())', 'import numpy as np\nN, K = map(int, input().split())\nN_lis=np.zeros(N)\nfor i in range(K):\n d=int(input())\n sweet=np.array(list(map(int, input().split())))\n #print(sweet)\n sweet-=1\n for j in sweet:\n N_lis[j]+=1\n#print(N_lis)\nno_sweet=N_lis==0\n#print(no_sweet)\nprint(no_sweet.sum())']
|
['Runtime Error', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Accepted']
|
['s339107706', 's538673547', 's979498992', 's994622063', 's935283640']
|
[27156.0, 27228.0, 8932.0, 27292.0, 27084.0]
|
[107.0, 108.0, 22.0, 114.0, 111.0]
|
[247, 243, 300, 299, 301]
|
p02688
|
u204198275
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['init=input().split()\nnum=init[0]\nsnacks=init[1]\nceck=[]\nfor i in range(snacks):\n sNum=input()\n if sNum>1:\n whos=input().split()\n for j in range(sNum):\n check.append()=whos[j]\n else:\n who=input()\n check.append()=who\n\nfor i in range(num):\n if not str(num[i]) in check:\n print(num)\n\n \n \n ', 'init=input().split()\nnum=int(init[0])\nsnacks=int(init[1])\ncheck=[]\n\nfor i in range(snacks):\n sNum=int(input())\n if sNum>1:\n whos=input().split()\n for j in range(sNum):\n check.append(whos[j])\n else:\n who=input()\n check.append(who)\n \nfor i in range(1,num):\n if str(i) not in check:\n print(i+1)', 'init=input().split()\nnum=int(init[0])\nsnacks=int(init[1])\ncheck=[]\n \nfor i in range(snacks):\n sNum=int(input())\n if sNum>1:\n whos=input().split()\n for j in range(sNum):\n check.append(whos[j])\n else:\n who=input()\n check.append(who)\n \ncount=0\nfor i in range(1,num+1):\n if str(i) not in check:\n count=count+1\nprint(count)']
|
['Runtime Error', 'Wrong Answer', 'Accepted']
|
['s487767252', 's757226474', 's109948031']
|
[9088.0, 9352.0, 9348.0]
|
[21.0, 23.0, 23.0]
|
[316, 318, 344]
|
p02688
|
u206541745
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k = map(int, input().split())\n\ncount=[0]*(n+1)\n\nfor i in range(k):\n d=int(input())\n a=list(map(int, input().split()))\n ans=0\n for i in range(len(a)):\n count[i]+=1\nprint(count.count(0))', 'n,k = map(int, input().split())\n\ncount=[0]*(n+1)\n\nfor i in range(n):\n d=int(input())\n a=list(map(int, input().split()))\n ans=0\n for i in range(len(a)):\n count[i]+=1\nprint(count.count(0))', 'n,k = map(int, input().split())\n\ncount=[0]*(n)\n\nfor i in range(k):\n d=int(input())\n a=list(map(int, input().split()))\n for x in a:\n count[x-1]+=1\nprint(count.count(0))']
|
['Wrong Answer', 'Runtime Error', 'Accepted']
|
['s036841106', 's435193815', 's866309937']
|
[9012.0, 9084.0, 9016.0]
|
[25.0, 29.0, 29.0]
|
[193, 198, 173]
|
p02688
|
u208187916
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N, K = map(int, input().split())\nA = set()\nfor i in range(K):\n #d = int(input())\n a = set(map(int, input().split()))\n A=A|a\n \nprint(N-len(A))', 'N, K = map(int, input().split())\nA = set()\nfor i in range(K):\n d = int(input())\n a = set(map(int, input().split()))\n A=A|a\n \nprint(N-len(A))']
|
['Wrong Answer', 'Accepted']
|
['s527979213', 's457391600']
|
[9164.0, 9172.0]
|
[23.0, 23.0]
|
[153, 152]
|
p02688
|
u208309047
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N, K = map(int, input().split())\nd = []\n\n\nC = [0 for i in range(N+1)]\nfor i in range(K):\n d.append(input()) \n\n A = list(map(int, input().split())) \n\n\n for v in A:\n C[v-1] = 1\n\n\nprint(N-sum(C))\nprint(d)\nprint(A)', 'N, K = map(int, input().split())\nd = []\n\n\nC = [0 for i in range(N+1)]\nfor i in range(K):\n d.append(input()) \n\n A = list(map(int, input().split())) \n\n\n for v in A:\n C[v-1] = 1\n\n\nprint(N-sum(C))\n\n']
|
['Wrong Answer', 'Accepted']
|
['s643400976', 's956596432']
|
[9076.0, 9032.0]
|
[24.0, 21.0]
|
[287, 271]
|
p02688
|
u211286909
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['\nd = []\nA = []\nfor i in range(K):\n _d = int(input())\n d.append(_d)\n _a = [int(x) for x in input().split()]\n A.append(_a)\n\nres = []\nfor i in range(1, N+1):\n res.append(i)\n\nfor a in A:\n for _a in a:\n if _a in res:\n res.remove(_a)\nprint(len(res))\n', 'N, K = [int(x) for x in input().split()]\n\nd = []\nA = []\nfor i in range(K):\n _d = int(input())\n d.append(_d)\n _a = [int(x) for x in input().split()]\n A.append(_a)\n\nres = []\nfor i in range(1, N+1):\n res.append(i)\n\nfor a in A:\n for _a in a:\n if _a in res:\n res.remove(_a)\nprint(len(res))\n']
|
['Runtime Error', 'Accepted']
|
['s836943100', 's812544033']
|
[9116.0, 9192.0]
|
[23.0, 24.0]
|
[280, 321]
|
p02688
|
u217836256
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['nk = input().split()\nNK =[int(x) for x in nk]\nt = []\ns = []\n\nfor i in range(1,NK[1]+1):\n s.append(i)\n d = int(input())\n A = input().split()\n a = [int(x) for x in A]\n t += a\nprint(t)\nset_t = set(t)\nset_s = set(s)\nr = set_s - set_t\nprint(len(r))', 'nk = input().split()\nNK =[int(x) for x in nk]\nt = []\ns = []\nfor l in range(1 ,NK[0]+1):\n s.append(l)\nfor i in range(1,NK[1]+1):\n d = int(input())\n A = input().split()\n a = [int(x) for x in A]\n t += a\nprint(t)\nset_t = set(t)\nset_s = set(s)\nr = set_s - set_t\nprint(len(r))', 'nk = input().split()\nNK =[int(x) for x in nk]\nt = []\ns = []\nfor i in range(1 ,NK[0]+1):\n\ts.append(i)\nfor i in range(1,NK[1]+1):\n d = int(input())\n A = input().split()\n a = [int(x) for x in A]\n t += a\nset_t = set(t)\nset_s = set(s)\nr = set_s - set_t\nprint(len(r))']
|
['Wrong Answer', 'Wrong Answer', 'Accepted']
|
['s546074648', 's958496732', 's263887515']
|
[9316.0, 9232.0, 9224.0]
|
[27.0, 24.0, 21.0]
|
[259, 284, 274]
|
p02688
|
u221061152
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
["N,K=map(int,input().split())\nkashi_num = [str(i+1) for i in range(N)]\nfor _ in range(K):\n d = input()\n for a in input().split():\n if a in kashi_num:\n kashi_num.remove(a)\n if len(kashi_num)==0:\n break\nprint(' '.join(kashi_num))", "N,K=map(int,input().split())\nkashi_num = [str(i+1) for i in range(N)]\nfor _ in range(K):\n d = input()\n for a in input().split():\n if a in kashi_num:\n kashi_num.remove(a)\nprint(' '.join(kashi_num))", 'N,K=map(int,input().split())\nkashi_num = [str(i+1) for i in range(N)]\nfor _ in range(K):\n d = input()\n for a in input().split():\n if a in kashi_num:\n kashi_num.remove(a)\n if len(kashi_num)==0:\n break\nprint(len(kashi_num))']
|
['Wrong Answer', 'Wrong Answer', 'Accepted']
|
['s628022020', 's923926691', 's845679296']
|
[9156.0, 9108.0, 9140.0]
|
[23.0, 24.0, 24.0]
|
[240, 206, 235]
|
p02688
|
u231518782
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['L = []\n\nwhile True:\n l = list(map(int, input().split()))\n if l:\n L.append(l)\n else:\n break\n\nprint(L)\n\nN = L[0][0]\nK = L[0][1]\n\nNum = list(range(1, N + 1, 1))\n\nnew_L = L[2::2]\n\nnew_LL = sum(new_L, [])\nfor n in new_LL:\n if n in Num:\n Num.remove(n)\n\nprint(len(Num))', 'L = []\nwhile True:\n l = list(map(int, input().split()))\n if l:\n L.append(l)\n else:\n break\n\nN = L[0][0]\nK = L[0][1]\n\nNum = list(range(1,N+1,1))\n\nnew_L = L[2::2]\n\nnew_LL = sum(new_L,[])\nfor n in new_LL:\n if n in Num:\n Num.remove(n)\n\nprint(len(Num))\n', 'import sys\n\nL = []\n"""\nwhile True:\n l = input()\n if l == "":\n break\n else:\n L.append(list(map(int,l.split())))\n print(L)\n"""\nN,K = list(map(int,input().split()))\n\n\n\nfor a in range(2 * K):\n n = list(map(int,input().split()))\n L.append(n)\n\n#print("End",L)\n\nNum = list(range(1, N + 1, 1))\n#print(Num)\nnew_L = L[1::2]\n#print(new_L)\n\nnew_LL = sum(new_L, [])\nfor n in new_LL:\n if n in Num:\n Num.remove(n)\n\nprint(len(Num))']
|
['Runtime Error', 'Runtime Error', 'Accepted']
|
['s047789471', 's087002769', 's258126250']
|
[9204.0, 9056.0, 9156.0]
|
[23.0, 23.0, 24.0]
|
[295, 280, 472]
|
p02688
|
u238940874
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k = map(int,input().split())\nd=[]\nfor i in range(k*2):\n d.append(list(map(int,input().split())))\n\nans=[]\nfor i in range(1,len(d),2):\n ans.append(*d[i])\n\nans=len(set(ans))\nprint(n-ans)', 'n,k=map(int,input().split())\nsnuke=[0]*n\nfor i in range(k):\n d=int(input())\n a=list(map(int,input().split()))\n for j in a:\n snuke[j-1]+=1\nprint(snuke.count(0))']
|
['Runtime Error', 'Accepted']
|
['s586776077', 's781560269']
|
[9220.0, 9144.0]
|
[23.0, 21.0]
|
[191, 175]
|
p02688
|
u239889104
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n, k = map(int, input().split())\nsnukes = [0] * n\nfor _ in range(k):\n d = int(input())\n a = map(int, input().split())\n for i in a:\n snukes[i] += 1\n\nprint(snukes.count(0))', 'n, k = map(int, input().split())\nsnukes = [0] * n\nfor _ in range(k):\n d = int(input())\n a = map(int, input().split())\n for i in a:\n snukes[i - 1] += 1\n \nprint(snukes.count(0))']
|
['Runtime Error', 'Accepted']
|
['s899889293', 's135987823']
|
[9172.0, 9124.0]
|
[21.0, 21.0]
|
[176, 181]
|
p02688
|
u241544828
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N, K = map(int, input().split())\nlist=[]\nfor _ in range(K):\n d = int(input())\n S = input().split()\n list.extend(S)\nnum = collections.Counter(list)\nprint(N-num)\n\n ', 'from collections import Counter\nN, K = map(int, input().split())\nlist=[]\nfor _ in range(1,K+1):\n d = int(input())\n S = input().split()\n list.extend(S)\nnum = Counter(list)\nprint(N-len(num))']
|
['Runtime Error', 'Accepted']
|
['s779339317', 's871517021']
|
[9344.0, 9728.0]
|
[21.0, 25.0]
|
[174, 197]
|
p02688
|
u242580186
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
["import sys\nread = sys.stdin.readline\nimport time\nimport math\nimport itertools as it\ndef inp():\n return int(input())\ndef inpl():\n return list(map(int, input().split()))\nstart_time = time.perf_counter()\n# ------------------------------\n\nN, K = inpl()\ndp = [False] * N\nfor i in range(K):\n d = inp()\n A = inpl()\n for a in A:\n dp[A-1] = True\ncnt = 0\nfor bl in dp:\n if not bl:\n cnt += 1\nprint(cnt)\n\n# -----------------------------\nend_time = time.perf_counter()\nprint('time:', end_time-start_time, file=sys.stderr)", "import sys\nread = sys.stdin.readline\nimport time\nimport math\nimport itertools as it\ndef inp():\n return int(input())\ndef inpl():\n return list(map(int, input().split()))\nstart_time = time.perf_counter()\n# ------------------------------\n\nN, K = inpl()\ndp = [False] * N\nfor i in range(K):\n d = inp()\n A = inpl()\n for a in A:\n dp[a-1] = True\ncnt = 0\nfor bl in dp:\n if not bl:\n cnt += 1\nprint(cnt)\n\n# -----------------------------\nend_time = time.perf_counter()\nprint('time:', end_time-start_time, file=sys.stderr)"]
|
['Runtime Error', 'Accepted']
|
['s059924046', 's268638487']
|
[9156.0, 9156.0]
|
[25.0, 25.0]
|
[540, 540]
|
p02688
|
u242890210
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['[N, K] = list(map(int, input().split()))\nall_A =[]\nfor i in range(N):\n all_A.append(i)\nfor j in range(K):\n d = int(input())\n A = list(map(int, input().split()))\n after_A = set(all_A) ^ set(A)\nprint(len(after_A))', '[N, K] = list(map(int, input().split()))\nall_A =[]\n\nfor i in range(1, N + 1):\n all_A.append(i)\nfor j in range(K):\n d = int(input())\n A = list(map(int, input().split()))\n all_A = set(all_A) ^ set(A)\nprint(len(after_A))', '[N, K] = list(map(int, input().split()))\nall_A =[]\nA_ = []\nfor i in range(1, N + 1):\n all_A.append(i)\nfor j in range(K):\n d = int(input())\n A = list(map(int, input().split()))\n A_ = A_.append(A)\nall_A = set(all_A) ^ set(A_)\nprint(len(all_A))', '[N, K] = list(map(int, input().split()))\nall_A =[]\nfor i in range(1, N + 1):\n all_A.append(i)\nfor j in range(K):\n d = int(input())\n A = list(map(int, input().split()))\n after_A = set(all_A) ^ set(A)\nprint(len(after_A))', '[N, K] = list(map(int, input().split()))\nall_A =[]\n\nfor i in range(1, N + 1):\n all_A.append(i)\nfor j in range(K):\n d = int(input())\n A = list(map(int, input().split()))\n all_A = set(all_A) ^ set(A)\nprint(len(all_A))', '[N, K] = list(map(int, input().split()))\nall_A =[]\nAB = []\nfor i in range(1, N + 1):\n all_A.append(i)\nfor j in range(K):\n d = int(input())\n A = list(map(int, input().split()))\n AB = AB + A\nlast_A = set(all_A) ^ set(AB)\nprint(len(last_A))']
|
['Wrong Answer', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Accepted']
|
['s349503680', 's446702060', 's765467196', 's816690299', 's956028947', 's972443711']
|
[9200.0, 9152.0, 9204.0, 9208.0, 9152.0, 9312.0]
|
[24.0, 21.0, 25.0, 22.0, 25.0, 25.0]
|
[223, 229, 253, 230, 227, 249]
|
p02688
|
u243714267
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
["import sys\nimport os\nf = open('input.txt', 'r')\nsys.stdin = f\n\nn, k = map(int, input().split())\n\nmans = [0]*n\nfor i in range(k):\n d = input()\n a = list(map(int, input().split()))\n for aa in a:\n mans[aa-1] += 1\n\ncnt = 0\nfor m in range(len(mans)):\n if mans[m] == 0:\n cnt += 1\n\nprint(cnt)\n", 'n, k = map(int, input().split())\n\nmans = [0]*n\nfor i in range(k):\n d = input()\n a = list(map(int, input().split()))\n for aa in a:\n mans[aa-1] += 1\n\ncnt = 0\nfor m in range(len(mans)):\n if mans[m] == 0:\n cnt += 1\n\nprint(cnt)']
|
['Runtime Error', 'Accepted']
|
['s933015051', 's253133366']
|
[9120.0, 9188.0]
|
[22.0, 20.0]
|
[312, 248]
|
p02688
|
u246907970
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['l1=input().split(" ")\nn=int(l1[0])\nk=int(l1[1])\nlist=[range(n)]\nkashi=[]\nfor i in range(k):\n tmp=input()\n num=input().split(" ")\n kashi.append(num)\nkashi=set(kashi)\nprint(n-len(kashi))', 'l1=input().split(" ")\nn=int(l1[0])\nk=int(l1[1])\nlist=[range(n)]\nkashi=[]\nfor i in range(k):\n tmp=input()\n num=input().split(" ")\n for j in num:\n kashi.append(j)\nkashi=set(kashi)\nprint(n-len(kashi))']
|
['Runtime Error', 'Accepted']
|
['s772209984', 's670970087']
|
[9480.0, 9512.0]
|
[23.0, 23.0]
|
[187, 203]
|
p02688
|
u250061066
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N,K=map(int, input().split())\ns=[]\nfor i in range(K):\n d=int(input())\n for j in range(d):\n s+=[int(input())]\ns=set(s)\nprint(N-len(s))', 'N,K=map(int, input().split())\ns=[]\nfor i in range(K):\n d=int(input())\n for j in range(d):\n s+=[int(input())]\ns=set(s)\n#print(s)\ns=list(s)\n#print(s)\ns.sort()\n#print(s)\nprint(N-len(s))', 'N,K=map(int, input().split())\ns=[]\nfor i in range(K):\n d=int(input())\n a=list(map(int, input().split()))\n for j in range(len(a)):\n s+=[a[j]]\ns=set(s)\n#print(s)\ns=list(s)\n#print(s)\ns.sort()\n#print(s)\nprint(N-len(s))']
|
['Runtime Error', 'Runtime Error', 'Accepted']
|
['s081382514', 's402615521', 's370281549']
|
[9180.0, 9184.0, 9188.0]
|
[23.0, 24.0, 21.0]
|
[146, 195, 230]
|
p02688
|
u251843176
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N,K = map(int,input().split())\ncnt = {num+1:0 for num in range(N)}\nfor i in range(K):\n d = int(input())\n num = list(map(int,input().split()))\n for j in range(d):\n cnt[num[j]]+=1\nfor k in range(len(cnt)):\n if cnt[k+1] == 0:\n print(k+1)\n ', 'N,K = map(int,input().split())\ncnt = [0]*(N+1)\nfor i in range(K):\n d = int(input())\n num = list(map(int,input().split()))\n for j in range(d):\n cnt[num[j]]+=1\nprint(cnt.count(0)-1)']
|
['Wrong Answer', 'Accepted']
|
['s864438911', 's801526499']
|
[9192.0, 9132.0]
|
[25.0, 22.0]
|
[269, 195]
|
p02688
|
u253527353
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
["x = input().split()\n\nn = int(x[0])\nk = int(x[1])\nds = []\nbool_array = [0]*n\n\nfor num in range(k):\n di = int(input())\n ajs_input = input().split(' ')\n for j in range(di):\n bool_array[int(ajs_input[j])-1] = 1\n \nprint(n - np.array(bool_array).sum())\n", "import numpy as np\n\nx = input().split()\n\nn = int(x[0])\nk = int(x[1])\nds = []\nbool_array = [0]*n\n\nfor num in range(k):\n di = int(input())\n ajs_input = input().split(' ')\n for j in range(di):\n bool_array[int(ajs_input[j])-1] = 1\n \nprint(n - np.array(bool_array).sum())"]
|
['Runtime Error', 'Accepted']
|
['s511793811', 's357663852']
|
[9156.0, 27208.0]
|
[22.0, 108.0]
|
[259, 278]
|
p02688
|
u258325541
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['S = list(map(int,input().split()))\ncounter = 0\nnuske = []\n\nfor k in range(S[0]):\n nuske.append(int(0))\n\nfor i in range(S[1]):\n roop = int(input())\n for j in range(roop):\n if roop == 1:\n temp = int(input())\n nuske[temp-1] = nuske[temp-1] + 1\n else:\n temp = list(map(int,input().split()))\n for l in temp:\n nuske[l-1] = nuske[l-1] + 1\n\nfor y in nuske:\n if y == 0:\n counter += 1\nprint(counter)\n ', 'S = list(map(int,input().split()))\ncounter = 0\nnuske = []\n\nfor k in range(S[0]):\n nuske.append(int(0))\n\nfor i in range(S[1]):\n roop = int(input())\n if roop == 1:\n temp = int(input())\n nuske[temp-1] = nuske[temp-1] + 1\n else:\n temp = list(map(int,input().split()))\n for l in temp:\n nuske[l-1] = nuske[l-1] + 1\n\nfor y in nuske:\n if y == 0:\n counter += 1\nprint(counter)\n ']
|
['Runtime Error', 'Accepted']
|
['s056554030', 's919724686']
|
[9160.0, 9200.0]
|
[22.0, 24.0]
|
[434, 396]
|
p02688
|
u262065571
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N, K = map(int, input().split())\na = []\nfor i in range(K):\n di = int(input())\n for j in range(di):\n a.append(map(int, input().split())\n\na = set(a)\nprint(N - len(a)) \n ', 'N, K = map(int, input().split())\na = []\nfor i in range(K):\n di = int(input())\n a += list(map(int, input().split()))\n\na = set(a)\nprint(N - len(a)) \n ']
|
['Runtime Error', 'Accepted']
|
['s372738641', 's197652862']
|
[8844.0, 9288.0]
|
[23.0, 22.0]
|
[187, 165]
|
p02688
|
u262244504
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k = map(int,input().split())\n\nd = [0 for i in range(k)]\na = [0 for i in range(k)]\n\nfor i in range(k):\n d[i]=int(input())\n a[i]=list(map(int,input().split()))\n\nl=[]\nfor c in range(len(a)):\n l.extend(a[c])\nls=list(set(l))\nprint(ls)\nprint(n-len(ls))', 'n,k = map(int,input().split())\n\nd = [0 for i in range(k)]\na = [0 for i in range(k)]\n\nfor i in range(k):\n d[i]=int(input())\n a[i]=list(map(int,input().split()))\n\nl=[]\nfor c in range(len(a)):\n l.extend(a[c])\nls=list(set(l))\nprint(n-len(ls))']
|
['Wrong Answer', 'Accepted']
|
['s890316599', 's478450408']
|
[9240.0, 9208.0]
|
[23.0, 23.0]
|
[257, 247]
|
p02688
|
u264312747
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n, k = map(int, input().split())\nkun_list = [1] * n\nfor i in range(0, k):\n print(kun_list)\n d = int(input())\n a_list = list(map(int, input().split()))\n for a in a_list:\n kun_list[a-1] = 0\n print(kun_list)\nprint(sum(kun_list))', 'n, k = map(int, input().split())\nkun_list = [1] * n\nfor i in range(0, k):\n d = int(input())\n a_list = list(map(int, input().split()))\n for a in a_list:\n kun_list[a-1] = 0\nprint(sum(kun_list))']
|
['Wrong Answer', 'Accepted']
|
['s974855936', 's361822465']
|
[9184.0, 9140.0]
|
[22.0, 23.0]
|
[233, 197]
|
p02688
|
u266795424
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N,K = map(int,input().split())\ns = [input() for i in range(K*2)]\nl = []\nc = 0\nk = 0\nm = 0\n\nnum = []\nfor i in range(K*2):\n if i%2==1:\n for m in range(int(s[i-1])):\n num.append(s[i].split()[m])\nfor j in (1,N):\n k=num.count(str(j))\n if k == 0:\n c = c+1\nprint(c)', 'N,K = map(int,input().split())\ns = [input() for i in range(K*2)]\nl = []\nc = 0\nk = 0\nm = 0\n\nnum = []\nfor i in range(K*2):\n if i%2==1:\n for m in range(int(s[i-1])):\n num.append(s[i].split()[m])\nfor j in (1,N):\n k=num.count(str(j))\n if k == 0:\n c = c+1\nprint(c)', 'N,K = map(int,input().split())\ns = [input() for i in range(K*2)]\nl = []\nc = 0\nk = 0\nm = 0\nf = []\n\nnum = []\nfor i in range(K*2):\n if i%2==1:\n for m in range(int(s[i-1])):\n num.append(s[i].split()[m])\nfor j in range(1,N+1):\n f.append(num.count(str(j)))\nprint(f.count(0))']
|
['Wrong Answer', 'Wrong Answer', 'Accepted']
|
['s224589045', 's430625757', 's513690362']
|
[9352.0, 9284.0, 9360.0]
|
[51.0, 54.0, 68.0]
|
[313, 313, 319]
|
p02688
|
u268724304
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['# -*- coding: utf-8 -*-\n\nN, K = map(int, input().split())\nd = [0]*K\n\nC = [0]*N\nfor i in range(K):\n d[i]=int(input())\n A=list(map(int, input().split()))\n for j in range(N):\n for k in range(d[i]):\n if A[k]==j+1:\n C[j]=1\n break\n\ncount=0\nfor i in range(N):\n if C[i]==0\n count+1\n\n\nprint("{}".format(count))\n', '# -*- coding: utf-8 -*-\n\nN, K = map(int, input().split())\nd = [0]*K\n\nC = [0]*N\nfor i in range(K):\n d[i]=int(input())\n A=list(map(int, input().split()))\n for j in range(N):\n for k in range(d[i]):\n if A[k]==j+1:\n C[j]=1\n break\n\ncount=0\nfor i in range(N):\n if C[i]==0:\n count=count+1\n\n#print("{}".format(C))\nprint("{}".format(count))\n']
|
['Runtime Error', 'Accepted']
|
['s256049727', 's390697551']
|
[8996.0, 9200.0]
|
[21.0, 66.0]
|
[365, 398]
|
p02688
|
u270886147
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['import numpy\nN,K = map(int,input().split())\na= [input().split() for l in range(2*K)]\nb=a[1::2]\n\nk=[0]*N\nfor i in range(K) :\n for j in range(N):\n if (b[i].count(str(j+1))) > 0 :\n k[j]+=1\n\nprint(k)\ncount=0\nfor i in range(N):\n if k[i]==0:\n count+=1\n\nprint(count)\n', 'import numpy\nN,K = map(int,input().split())\na= [input().split() for l in range(2*K)]\nb=a[1::2]\n\nk=[0]*N\nfor i in range(K) :\n for j in range(N):\n if (b[i].count(str(j+1))) > 0 :\n k[j]+=1\n\ncount=0\nfor i in range(N):\n if k[i]==0:\n count+=1\n\nprint(count)\n']
|
['Wrong Answer', 'Accepted']
|
['s591002131', 's627209129']
|
[27536.0, 27612.0]
|
[110.0, 120.0]
|
[291, 282]
|
p02688
|
u273186459
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k=map(int,input().split())\nd=list()\narray=list()\nfor i in range(k):\n\td.extend(input())\n\tarray.extend(input())\n\n\nprint(n-len(set(array)))', 'n,k=map(int,input().split())\nd=list()\narray=list()\nprint(k)\nfor i in range(k):\n\td.extend(input())\n\tarray.extend(input())\n\n\nprint(n-len(set(array)))', 'n,k=map(int,input().split())\nd=list()\narray=list()\nfor i in range(k):\n\td.extend(input())\n\tarray.extend(input().split())\n\nprint(n-len(set(array)))']
|
['Wrong Answer', 'Wrong Answer', 'Accepted']
|
['s793101324', 's795032568', 's062533478']
|
[9180.0, 9284.0, 9536.0]
|
[23.0, 24.0, 21.0]
|
[138, 147, 145]
|
p02688
|
u275123539
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N,K=input().strip().split(" ")\nN=int(N)\nK=int(K)\ncheckbox=[False for i in range(N)]\nfor k in range(K):\n input()\n seq=input().strip().split(" ")\n for j in seq:\n checkbox[i]=True\nprint(checkbox.count(False))', 'N, K = input().strip().split(" ")\nN = int(N)\nK = int(K)\ncheckbox = [False for i in range(N)]\nfor k in range(K):\n input()\n seq = input().strip().split(" ")\n for j in seq:\n checkbox[int(j)-1] = True\nprint(checkbox.count(False))\n']
|
['Runtime Error', 'Accepted']
|
['s430543975', 's540812246']
|
[9152.0, 9176.0]
|
[20.0, 22.0]
|
[211, 242]
|
p02688
|
u275212209
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N, K = map(int, input().split())\n\nnum_list = []\nd = []\nfor i in range(N):\n try:\n d.append(list(map(int,input().split())))\n num_list.append(list(map(int,input().split())))\n except EOFError:\n pass\nA = set(sum(num_list, []))\n#print(A)\n\nppl = []\nfor i in range(N):\n ppl.append(N)\n N -= 1\n\npeople = set(ppl)\nsnack = set(A)\n\ns_difference = people - snack\nprint(s_difference)', 'N, K = map(int, input().split())\n\nnum_list = []\nd = []\nfor i in range(N):\n try:\n d.append(list(map(int,input().split())))\n num_list.append(list(map(int,input().split())))\n except EOFError:\n pass\n \n#those who has snack\nsnack = set(sum(num_list, []))\n\nppl = []\nfor i in range(N):\n ppl.append(N)\n N -= 1\n \nnsnack = set(ppl) - snack\nnosnack = list(nsnack)\n\nprint(len(nosnack))']
|
['Wrong Answer', 'Accepted']
|
['s105635656', 's307316701']
|
[9332.0, 9268.0]
|
[23.0, 25.0]
|
[389, 397]
|
p02688
|
u275242455
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N,K = map(int,input().split(" "))\ntrickSum = 0\nresult = list()\nwhile True :\n d = input()\n if d == "":\n break\n result = result + (list(map(int, input().split(" "))))\nprint(N - len(set(result)))', 'N,K = map(int,input().split(" "))\ntrickSum = 0\nresult = list()\nfor i in range(K):\n d = input()\n result = result + (list(map(int, input().split(" "))))\nprint(N - len(set(result)))']
|
['Runtime Error', 'Accepted']
|
['s183291680', 's528779984']
|
[9184.0, 9184.0]
|
[25.0, 22.0]
|
[208, 184]
|
p02688
|
u277429554
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['# 166 B\n\nn, k = map(int, input().split())\nl = []\nfor i in range(k):\n d = int(input())\n a = list(map(int, input().split()))\n l = l + a\n\nprint(n-len(set(a)))', '# 166 B\n\nn, k = map(int, input().split())\nl = []\nfor i in range(k):\n d = int(input())\n a = list(map(int, input().split()))\n l.extend(a)\n\nprint(n - (len(set(a))))', '# 166 B\n\nn, k = map(int, input().split())\nl = []\nfor i in range(k):\n d = int(input())\n a = list(map(int, input().split()))\n l.append(a)\n\nprint(n - (len(set(a))))', '# 166 B\n\nn, k = map(int, input().split())\nl = []\nfor i in range(k):\n d = int(input())\n a = list(map(int, input().split()))\n l = l + a\n\nprint(n-len(set(l)))']
|
['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted']
|
['s148990501', 's225694664', 's371233021', 's453578029']
|
[9120.0, 9112.0, 9080.0, 9268.0]
|
[29.0, 27.0, 27.0, 28.0]
|
[164, 170, 170, 164]
|
p02688
|
u279695802
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n, k = map(int, input().split())\nlst = []\nfor i in range(k):\n d = int(input())\n a = list(map(int, input().split()))\n lst.append(d)\nprint(n-d)', 'n, k = map(int, input().split())\ns = set()\nfor i in range(k):\n d = int(input())\n a = list(map(int, input().split()))\n for i in a:\n s.add(i)\nprint(n-len(s))']
|
['Wrong Answer', 'Accepted']
|
['s220600679', 's311480294']
|
[9184.0, 9180.0]
|
[23.0, 22.0]
|
[144, 161]
|
p02688
|
u279735925
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
["N, K = map(int, input().split())\n#print('N : ' + str(N))\n\nli = [0 for i in range(N)]\n\nfor i in range(0,K): \n d = int(input())\n # print('')\n # print('d : ' + str(d))\n A = list(map(int, input().split()))\n print('<A>')\n for j in A:\n # print(j)\n li[j-1] = 1\nsum = 0\n#print(li)\n\nfor i in range(0,N):\n if li[i] == 0:\n sum += 1\nprint(sum)", "N, K = map(int, input().split())\n#print('N : ' + str(N))\n\nli = [0 for i in range(N)]\n\nfor i in range(0,K): \n d = int(input())\n # print('')\n # print('d : ' + str(d))\n A = list(map(int, input().split()))\n # print('<A>')\n for j in A:\n # print(j)\n li[j-1] = 1\nsum = 0\n#print(li)\n\nfor i in range(0,N):\n if li[i] == 0:\n sum += 1\nprint(sum)"]
|
['Wrong Answer', 'Accepted']
|
['s474204006', 's239028335']
|
[9204.0, 9144.0]
|
[23.0, 19.0]
|
[367, 368]
|
p02688
|
u283751459
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k = map(int,input().split())\n\ncount = [0]*(n+1)\ncount1 = 0\n\nfor i in range(k):\n d = int(input())\n A = list(map(int,input().split()))\n for i in A:\n count[i-1] += 1\n\nfor i in range(n):\n if count[i] == 0:\n count1 += 1\nprint(count)\nprint(count1)', 'n,k = map(int,input().split())\n\ncount = [0]*(n+1)\ncount1 = 0\n\nfor i in range(k):\n d = int(input())\n A = list(map(int,input().split()))\n for i in A:\n count[i-1] += 1\n\nfor i in range(n):\n if count[i] == 0:\n count1 += 1\n\nprint(count1)\n ']
|
['Wrong Answer', 'Accepted']
|
['s775798109', 's422298979']
|
[9188.0, 9176.0]
|
[27.0, 30.0]
|
[253, 246]
|
p02688
|
u290731659
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N, K = map(int, input().split())\nwithSnacks = []\nfor x in range(K):\n nUmsnakes = int(input)\n snakes = list(map(int, input().split()))\n withSnacks.extend(snakes)\nwithSnacks = list(set(withSnacks))\ncount = 0\nfor x in range(1, x + 1):\n if not x in withSnacks:\n count += 1\n\nprint(count)\n \n ', 'N, K = map(int, input().split())\nwithSnacks = []\nfor x in range(K):\n\tnUmsnakes = int(input())\n\tsnakes = list(map(int, input().split()))\n\twithSnacks.extend(snakes)\nwithSnacks = list(set(withSnacks))\ncount = 0\nfor x in range(1, N + 1):\n\tif not x in withSnacks:\n\t\tcount += 1\n \nprint(count)']
|
['Runtime Error', 'Accepted']
|
['s284446655', 's678418966']
|
[9184.0, 9188.0]
|
[21.0, 21.0]
|
[297, 286]
|
p02688
|
u293825440
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N,K = map(int,input().split())\nli = []\ncount = 0\nfor i in range(K):\n d = int(input())\n a = list(map(int,input().split()))\n li.append(a)\n\nfor i in range(N):\n if i+1 not in li:\n count += 1\n\nprint(count)', 'N,K = map(int,input().split())\nli = []\ncount = 0\nfor i in range(K):\n d = int(input())\n a = list(map(int,input().split()))\n for j in range(d):\n li.append(a[j])\n\nfor i in range(N):\n if i+1 not in li:\n count += 1\n\nprint(count)']
|
['Wrong Answer', 'Accepted']
|
['s724744822', 's160425624']
|
[9112.0, 9196.0]
|
[33.0, 31.0]
|
[219, 249]
|
p02688
|
u294385082
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k = map(int,input().split())\na = [i for i in range(n+1)]\nd = []\nA = []\n\nfor j in range(k):\n d.append(int(input()))\n A.append(list(map(int,input().split())))\n \n \nprint(d,A)\nfor i in A:\n for j in i:\n if j in a:\n a.remove(j)\n \n \nprint(len(a)-1)', 'n,k = map(int,input(),split())\na = [0 for i in range(n)]\n\nfor i in range k:\n d = int(input())\n A = list(map(int,input(),split()))\n for j in A:\n a[j-1] += 1\n \nprint(a.count(0))', '\nn,k = map(int,input().split())\na = [0 for i in range(n)]\n \nfor i in range(k):\n d = int(input())\n A = list(map(int,input().split()))\n for j in A:\n a[j-1] += 1\n \nprint(a.count(0))']
|
['Wrong Answer', 'Runtime Error', 'Accepted']
|
['s385366286', 's763004154', 's393445431']
|
[9172.0, 8884.0, 9180.0]
|
[23.0, 22.0, 23.0]
|
[266, 190, 189]
|
p02688
|
u296989351
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n, k = map(int, input().split())\nsnuke = [1 for i in range(n)]\nfor _ in range(k):\n\td = int(input())\n\ta = list(map(int, input().split()))\n\tfor i in range(a):\n\t\tsnuke[i -1] = 0\n\t\t\nprint(sum(snuke))', 'n, k = map(int, input().split())\nsnuke = [1 for i in range(n)]\nfor _ in range(k):\n\td = int(input())\n\ta = list(map(int, input().split()))\n\tfor i in a:\n\t\tsnuke[i -1] = 0\n\t\t\nprint(sum(snuke))']
|
['Runtime Error', 'Accepted']
|
['s940219496', 's276343951']
|
[9184.0, 9180.0]
|
[22.0, 22.0]
|
[195, 188]
|
p02688
|
u297089927
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['import collections\nli=[]\nn,k=map(int,input().split())\nfor i in range(k):\n d=int(input())\n lik=list(map(int,input().split()))\n li+=lik\nprint(li)\nli=collections.Counter(li)\nans=0\nfor j in range(1,n+1):\n if li[j]==0:\n ans+=1\nprint(ans)\n', 'import collections\nli=[]\nn,k=map(int,input().split())\nfor i in range(k):\n d=int(input())\n lik=list(map(int,input().split()))\n li+=lik\nli=collections.Counter(li)\nans=0\nfor j in range(1,n+1):\n if li[j]==0:\n ans+=1\nprint(ans)\n']
|
['Wrong Answer', 'Accepted']
|
['s020768124', 's874985818']
|
[9552.0, 9480.0]
|
[26.0, 24.0]
|
[252, 242]
|
p02688
|
u297667660
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N, K = map(int, input().split())\nlist_A = [1]*N\nfor i in range(K):\n d = int(input())\n l = list(map(int, input().split()))\n for J range(d):\n if list_A[l[j]-1] == 1:\n list_A[l[j]-1] = 0\n\nprint(list_A.count(1)) \n \n ', 'N, K = map(int, input().split())\nlist_A = [1]*N\nfor i in range(K):\n d = int(input())\n l = list(map(int, input().split()))\n for j in range(d):\n if list_A[l[j]-1] == 1:\n list_A[l[j]-1] = 0\n\nprint(list_A.count(1)) ']
|
['Runtime Error', 'Accepted']
|
['s749094782', 's357474218']
|
[9020.0, 9188.0]
|
[24.0, 24.0]
|
[262, 247]
|
p02688
|
u302084097
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N,K=map(int,input().split())\nsunuke=[]\nfor i in range(K):\n d=int(input())\n okashi=input().split()\n for i in range(d):\n sunuke.append(okashi[i])\n\nhave_okashi=collections.Counter(sunuke)\nprint(N-len(have_okashi))\n', 'import collections\nN,K=map(int,input().split())\nsunuke=[]\nfor i in range(K):\n d=int(input())\n okashi=input().split()\n for i in range(d):\n sunuke.append(okashi[i])\n\nhave_okashi=collections.Counter(sunuke)\nprint(N-len(have_okashi))']
|
['Runtime Error', 'Accepted']
|
['s070936999', 's274474090']
|
[9664.0, 9804.0]
|
[20.0, 21.0]
|
[227, 245]
|
p02688
|
u306516971
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N, K = map(int, input().split())\nli = []\nansli = []\nfor i in range(K):\n d = int(input())\n li.extend(list(map(int, input().split())))\nprint(li)\nfor i in range(1, N+1):\n if i not in li:\n ansli.append(i)\nprint(len(ansli))', 'N, K = map(int, input().split())\nli = []\nansli = []\nfor i in range(K):\n d = int(input())\n li.extend(list(map(int, input().split())))\nfor i in range(1, N+1):\n if i not in li:\n ansli.append(i)\nprint(len(ansli))']
|
['Wrong Answer', 'Accepted']
|
['s964102462', 's319846775']
|
[9192.0, 9208.0]
|
[21.0, 22.0]
|
[234, 224]
|
p02688
|
u309018392
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k = map(int,input().split())\ncount = []\nfor i in range(1,n+1):\n count.append(i)\n \nfor j in range(k):\n d = int(input())\n A = list(map(int,input().split()))\n\nprint(len(set(count)-set(A)))\n ', 'n,k = map(int,input().split())\ncount = []\nfor i in range(1,n+1):\n count.append(i)\n \nfor j in range(k):\n d = int(input())\n A = list(map(int,input().split()))\n ans = set(count)-set(A)\n \nprint(len(ans))', 'n,k = map(int,input().split())\ncount = []\nfor i in range(1,n+1):\n count.append(i)\n \nfor j in range(k):\n d = int(input())\n A = list(map(int,input().split()))\n ans = len(set(count)-set(A))\n \nprint(ans)\n', 'n,k = map(int,input().split())\ncount = []\nfor i in range(1,n+1):\n count.append(i)\n \nfor i in range(k):\n d = int(input())\n A = list(map(int,input().split()))\n ans = set(count)-set(A)\n \nprint(len(ans))', 'N,K = map(int,input().split())\ncount = []\nfor i in range(1,N+1):\n count.append(i)\n \nfor i in range(K):\n d = int(input())\n A = list(map(int,input().split()))\n count = set(count) - set(A)\nprint(len(count))']
|
['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted']
|
['s229629612', 's375783661', 's970251409', 's993391150', 's375148082']
|
[9092.0, 9112.0, 9080.0, 9104.0, 9192.0]
|
[20.0, 23.0, 22.0, 21.0, 22.0]
|
[204, 217, 218, 217, 218]
|
p02688
|
u309120194
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N, K = map(int, input().split())\nd = []\nA = []\nfor _ in range(K):\n d.append(int(input()))\n A.append(list(map(int, input().split())))\n\nl = [1]*N\nfor i in range(K):\n for j in range(d[i]):\n print(i, j)\n print(A[i][j])\n l[A[i][j]-1] = 0\n \nprint(sum(l))', 'N,K = map(int ,input().split())\nD = []\nA = []\nfor _ in range(K):\n D.append(int(input()))\n A.append(list(map(int, input().split())))\n\n\nl = [0]*N\nfor i in range(K):\n for j in range(D[i]):\n l[A[i][j]-1] = 1\n\nprint(N - sum(l))']
|
['Wrong Answer', 'Accepted']
|
['s429324459', 's389224884']
|
[9280.0, 9200.0]
|
[38.0, 31.0]
|
[263, 363]
|
p02688
|
u313111801
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N,K=map(int,input().split())\ncnt=[0]*N\nfor i in range(K):\n d=int(input())\n A=list(map(int(),input().split()))\n for a in A:\n cnt[a-1]=cnt[a-1]+1\nans=0\nfor i in range(N):\n if cnt[i]==0:\n ans=ans+1\nprint(ans)\n\n\n', 'N,K=map(int,input().split())\ncnt=[0]*N\nfor i in range(K):\n d=int(input())\n A=list(map(int,input().split()))\n for a in A:\n cnt[a-1]=cnt[a-1]+1\nans=0\nfor i in range(N):\n if cnt[i]==0:\n ans=ans+1\nprint(ans)\n\n\n']
|
['Runtime Error', 'Accepted']
|
['s627880627', 's193522273']
|
[9064.0, 9024.0]
|
[25.0, 32.0]
|
[234, 232]
|
p02688
|
u315759831
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['NK = list(map(int, input().split()))\nans = [1]*NK[0]\n\nfor i in range(0,NK[1]):\n d = int(input())\n table = list(map(int, input().split()))\n for j in range(0,NK[0]):\n if table.count(j) == 0:\n ans[j] = 0\nprint(NK[0]-sum(ans))', 'NK = list(map(int, input().split()))\nans = [0]*NK[0]\n\nfor i in range(0,NK[1]):\n d = int(input())\n table = list(map(int, input().split()))\n for j in range(1,NK[0]+1):\n if table.count(j) != 0:\n ans[j-1] = 1\nprint(NK[1]-sum(ans))', 'N = int(input())\nK = int(input())\nans = [1]*N\n\nfor i in range(0,K):\n d = int(input())\n table = list(map(int, input().split()))\n for j in range(0,N):\n if table.count(j) != 0:\n ans[j] = 0\nprint(sum(ans))', 'N = input()\nK = input()\nans = [1]*N\n\nfor i in range(0,K):\n d = int(input())\n table = list(map(int, input().split()))\n for j in range(0,N):\n if table.count(j) != 0:\n ans[j] = 0\nprint(sum(ans))', 'N = int(input())\nK = int(input())\nans = [1]*N\n\nfor i in range(0,K):\n d = int(input())\n table = list(map(int, input().split()))\n for j in range(0,N):\n if table.count(j) == 0:\n ans[j] = 0\nprint(1-sum(ans))', 'NK = list(map(int, input().split()))\nans = [0]*NK[0]\n\nfor i in range(0,NK[1]):\n d = int(input())\n table = list(map(int, input().split()))\n for j in range(0,NK[0]):\n if table.count(j) != 0:\n ans[j] = 0\nprint(NK[1]-sum(ans))', 'NK = list(map(int, input().split()))\nans = [0]*NK[0]\n\nfor i in range(0,NK[1]):\n d = int(input())\n table = list(map(int, input().split()))\n for j in range(0,NK[0]):\n if table.count(j) == 1:\n ans[j] = 0\nprint(NK[1]-sum(ans))', 'NK = list(map(int, input().split()))\nans = [0]*NK[0]\n\nfor i in range(0,NK[1]):\n d = int(input())\n table = list(map(int, input().split()))\n for j in range(1,NK[0]+1):\n if table.count(j) != 0:\n ans[j-1] = 1\nprint(NK[0]-sum(ans))']
|
['Wrong Answer', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Accepted']
|
['s067747714', 's110636729', 's116213343', 's335854710', 's675940806', 's757879785', 's832497128', 's831980414']
|
[9212.0, 9116.0, 9192.0, 9028.0, 9104.0, 9092.0, 9088.0, 9160.0]
|
[36.0, 34.0, 22.0, 20.0, 21.0, 31.0, 31.0, 34.0]
|
[234, 238, 213, 203, 215, 234, 234, 238]
|
p02688
|
u318182140
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n, k = map(int, input().split())\nlis = []\nfor i in range(ki):\n lis.append(input().split())\nlis2 = []\nj = 1\nwhile j < ki:\n for j in li[i]:\n li2.append(j)\n j += 2\nlis2 = set(lis2)\nprint(n - len(lis2))\n', 'n, k = map(int, input().split())\nli = []\nfor x in range(k2):\n li.append(input().split())\nli2 = []\ni = 1\nwhile i < k2:\n for j in li[i]:\n li2.append(j)\n i += 2\nli2 = set(li2)\nprint(n - len(li2))', 'n, k = map(int, input().split())\nlis = []\nfor i in range(k*2):\n lis.append(input().split())\nlis2 = []\nj = 1\nwhile j < k*2:\n for k in lis[j]:\n lis2.append(k)\n j += 2\nlis2 = set(lis2)\nprint(n - len(lis2))', 'n, k = map(int, input().split())\nlis = []\nfor i in range(k*2):\n lis.append(input().split())\nlis2 = []\nj = 1\nwhile j < k*2:\n for k in lis[j]:\n li2.append(k)\n j += 2\nlis2 = set(lis2)\nprint(n - len(lis2))', 'n, k = map(int, input().split())\nlis = []\nfor i in range(k*2):\n lis.append(input().split())\nlis2 = []\nj = 1\nwhile j < k2:\n for k in lis[j]:\n lis2.append(k)\n j += 2\nlis2 = set(lis2)\nprint(n - len(lis2))', 'n, k = map(int, input().split())\nli = []\nfor x in range(k*2):\n li.append(input().split())\nli2 = []\ni = 1\nwhile i < k*2:\n for j in li[i]:\n li2.append(j)\n i += 2\nli2 = set(li2)\nprint(n - len(li2))']
|
['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted']
|
['s112575880', 's335845442', 's817219746', 's932327631', 's944842871', 's075964006']
|
[9180.0, 9168.0, 9476.0, 9356.0, 9524.0, 9664.0]
|
[22.0, 22.0, 22.0, 21.0, 24.0, 23.0]
|
[215, 208, 218, 217, 217, 210]
|
p02688
|
u319778238
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N, K = map(int, input().split())\n \ntmp = set()\n \nfor i in range(N):\n input()\n tmp |= set(map(int, input().split()))\n \nprint(len(set(range(1, N+1)) - tmp))', 'N, K = map(int, input().split())\n \ntmp = set()\n \nfor i in range(K):\n input()\n tmp |= set(input())\n \nprint(N - len(tmp) - 1)', 'N, K = map(int, input().split())\n \ntmp = [0] * N\n \nfor i in range(K):\n input()\n for j in set(map(int, input().split()))\n \ttmp[j] |= 1 \nprint(sum(tmp))', 'N, K = map(int, input().split())\n \ntmp = [0] * N\n \nfor i in range(K):\n input()\n for j in set(map(int, input().split())):\n \ttmp[j] |= 1 \nprint(sum(tmp))', 'N, K = map(int, input().split())\n \ntmp = [0] * N\n \nfor i in range(K):\n input()\n for j in map(int, input().split()):\n \ttmp[j-1] |= 1 \nprint(sum(tmp))', 'N, K = map(int, input().split())\n\ntmp = {}\n\nfor i in range(N):\n input()\n tmp |= set(map(int, input().split()))\n\nprint(len(set(range(1, N+1)) - tmp))', 'N, K = map(int, input().split())\n \ntmp = [0] * N\n \nfor i in range(K):\n input()\n for j in map(int, input().split()):\n tmp[j-1] |= 1 \nprint(sum(tmp))', 'N, K = map(int, input().split())\n \ntmp = [0] * N\n \nfor i in range(K):\n input()\n for j in map(int, input().split()):\n \ttmp[j-1] |= 1 \nprint(sum(tmp))\n', 'N, K = map(int, input().split())\n \ntmp = [0] * N\n \nfor i in range(K):\n input()\n for j in map(int, input().split()):\n tmp[j] |= 1\n \nprint(sum(tmp))', 'N, K = map(int, input().split())\n \ntmp = [0] * N\n \nfor i in range(K):\n input()\n for j in map(int, input().split()):\n \ttmp[j] |= 1 \nprint(sum(tmp))\n', 'N, K = map(int, input().split())\n \ntmp = set()\n \nfor i in range(K):\n input()\n tmp |= set(input().split())\n \nprint(N - len(tmp))\n']
|
['Runtime Error', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted']
|
['s172908423', 's221591610', 's337057302', 's850788485', 's876012958', 's883825381', 's890879956', 's904580757', 's954794617', 's955139182', 's836422457']
|
[9188.0, 9048.0, 8904.0, 8864.0, 9028.0, 9184.0, 9112.0, 8960.0, 9124.0, 8964.0, 9160.0]
|
[26.0, 27.0, 28.0, 24.0, 24.0, 22.0, 33.0, 27.0, 25.0, 24.0, 29.0]
|
[156, 125, 152, 153, 150, 150, 152, 151, 151, 149, 130]
|
p02688
|
u321096814
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
["\nimport sys\nimport itertools\n \n \nN, K = map(int, input().split())\n\nnums = [ ]\nfor _ in range(N):\n _ = int(input())\n nums.extend([int(x.strip()) for x in input().split(' ') ])\n\nprint(N - len(set(nums)))", "\nimport sys\nimport itertools\n \n \nN, K = map(int, input().split())\n\nnums = [ ]\nfor _ in range(K):\n _ = int(input())\n nums.extend([int(x.strip()) for x in input().split(' ') ])\n\nprint(N - len(set(nums)))"]
|
['Runtime Error', 'Accepted']
|
['s722539228', 's193437528']
|
[9244.0, 9084.0]
|
[25.0, 24.0]
|
[208, 208]
|
p02688
|
u325270534
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n, k = map(int, input().split())\nlist1, list2, k = [], [], k*2\nfor x in range(k):\n list1.append(input().split())\nwhile i < k:\n for j in list1[i]:\n list2.append(j)\n i += 2\nprint(n - len(set(list2)))', 'n, k = map(int, input().split())\nlist1, list2, k = [], [], k*2\nfor x in range(k):\n list1.append(input().split())\nwhile i < k:\n for j in list1[i]:\n list2.append(j)\n i += 2\nprint(n - len(set(list2)))\n', 'n, k = map(int, input().split())\nli = []\nfor x in range(k*2):\n li.append(input().split())\nli2 = []\ni = 1\nwhile i < k*2:\n for j in li[i]:\n li2.append(j)\n i += 2\nli2 = set(li2)\nprint(n - len(li2))']
|
['Runtime Error', 'Runtime Error', 'Accepted']
|
['s272027061', 's972941844', 's618423177']
|
[9536.0, 9360.0, 9360.0]
|
[23.0, 22.0, 22.0]
|
[213, 214, 210]
|
p02688
|
u329608654
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N,K =map(int , input().split())\nA = []\nfor i in range(K):\n d = int(input())\n A += map(int , input().split())\n print(set(A))\nprint(N-len(set(A)))', 'N,K =map(int , input().split())\nA = []\nfor i in range(K):\n d = int(input())\n A += map(int , input().split())\nprint(N-len(set(A)))']
|
['Wrong Answer', 'Accepted']
|
['s778349391', 's851817305']
|
[9180.0, 9044.0]
|
[24.0, 23.0]
|
[147, 131]
|
p02688
|
u331956460
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N=input()\nK=input()\nl=[]\nfor k in range(K):\n a=input()\n for i in range(a):\n l.append(input())\n \nfor j in range(N):\n if j not in l:\n print(j)\n\n\n\n', 'N,K=map(int,input().split())\nl = []\nfor k in range(K):\n a = int(input())\n lis=list(map(int,input().split()))\n l.extend(lis)\nfor j in range(N):\n if not j+1 in l:\n print(j+1)', 'N = int(input())\nK = int(input())\nl = []\nfor k in range(K):\n a = int(input())\n for i in range(a):\n l.append(int(input()))\nprint(l)\nfor j in range(N):\n if not j+1 in l:\n print(j+1)', 'N=input()\nK=input()\nl=[]\nfor k in range(K):\n a=input()\n for i in range(a):\n l.append(input())\n \nfor j in range(N):\n if j != in l:\n print(j)\n\n\n\n', 'N,K=map(int,input().split())\nl = []\nfor k in range(K):\n a = int(input())\n lis=list(map(int,input().split()))\n print(lis)\n l.extend(lis)\nprint(l)\nfor j in range(N):\n if not j+1 in l:\n print(j+1)', 'N,K=map(int,input().split())\nl = []\nfor k in range(K):\n a = int(input())\n lis=list(map(int,input().split()))\n l.extend(lis)\nc=0\nfor j in range(N):\n if not j+1 in l:\n c+=1\nprint(c)']
|
['Runtime Error', 'Wrong Answer', 'Runtime Error', 'Runtime Error', 'Wrong Answer', 'Accepted']
|
['s033984481', 's408380155', 's658167865', 's927998002', 's994156610', 's380312620']
|
[8988.0, 9076.0, 9192.0, 8792.0, 9032.0, 9112.0]
|
[23.0, 23.0, 25.0, 20.0, 24.0, 20.0]
|
[154, 191, 202, 153, 215, 198]
|
p02688
|
u335406314
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
["N,K = list(map(int, input('').split(' ')))\nD = set()\nfor i in range(K):\n input('')\n [D.add(j) for j in map(int, input('').split(' '))]\nprint(K-len(D))", "N,K = list(map(int, input('').split(' ')))\nD = set()\nfor i in range(K):\n input('')\n D |= set(map(int, input('').split(' ')))\nprint(K-len(D))", "N,K = list(map(int, input('').split(' ')))\nD = set()\nfor i in range(K):\n input('')\n D |= set(map(int, input('').split(' ')))\nprint(N-len(D))"]
|
['Wrong Answer', 'Wrong Answer', 'Accepted']
|
['s559035322', 's991459668', 's601619254']
|
[9172.0, 9136.0, 9084.0]
|
[28.0, 30.0, 30.0]
|
[152, 142, 142]
|
p02688
|
u336968242
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['NK=input().split()\nN=int(NK[0])\nK=int(NK[1])\nlistd=[]\nlistA=[]\nfor i in range(K):\n listd.append(input())\n listA.append(input().split())\nans=0\nfor a in range(1,N+1):\n n=0\n for i in range(1,K+1):\n for j in range(1,int(listd[i-1])+1):\n if a==listA[i-1][j-1]:\n n+=1\n else:\n pass\n if n==0:\n ans+=1\nprint(ans)\n', '[N,K]=list(map(int, input().split()))\ndlist=[]\nalist=[]\nfor i in range(K):\n d=int(input())\n dlist.append(d)\n alist.append(list(map(int, input().split())))\nnlist=[n for n in range(1,N+1)]\nans=0\nfor n in range(1,N+1):\n flg=True\n for als in alist:\n if n in als:\n flg=False\n break\n if flg:\n ans+=1\nprint(ans)\n']
|
['Wrong Answer', 'Accepted']
|
['s860377103', 's865863529']
|
[9412.0, 9208.0]
|
[145.0, 22.0]
|
[385, 359]
|
p02688
|
u342062419
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['import math\nx = int(input())\nn = 100\ny = 0\n\nwhile x > n:\n \n n += n // 100\n y += 1\n\nprint(y)', 'n,k = map(int, input().split())\n\nd = [0] * n\n\nfor i in range(k):\n \n m = int(input())\n \n a = list(map(int, input().split()))\n for j in a:\n \n d[a[j]-1] = 1 \n \n\nans = 0\nfor i in range(n):\n if d[i] == 0:\n ans += 1\n\nprint(ans)', '# ABC166 B\nn,k = map(int, input().split())\n\nd = [0] * n\n\nfor i in range(k):\n \n m = int(input())\n \n a = list(map(int, input().split()))\n for j in a:\n \n d[j-1] = 1 \n \n\nans = 0\nfor i in range(n):\n if d[i] == 0:\n ans += 1\n\nprint(ans)']
|
['Runtime Error', 'Runtime Error', 'Accepted']
|
['s213165662', 's483520396', 's194348450']
|
[9080.0, 9140.0, 9084.0]
|
[28.0, 22.0, 32.0]
|
[129, 639, 647]
|
p02688
|
u345483150
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k=map(int,input().split())\nl=[0]*n\nfor i in range(k):\n d=int(input())\n for j in range(d):\n a=int(input())\n l[a-1]=1\nprint(l.count(0))', 'n,k=map(int,input().split())\nl=[0]*n\nfor i in range(k):\n d=int(input())\n h=[int(input()) for i in range(d)]\n for j in d:\n l[j-1]=1\nprint(l.count(0))', 'n,k=map(int,input().split())\nl=[0]*n\nfor i in range(k):\n d=int(input())\n h=list(map(int,input().split()))\n for j in h:\n l[j-1]=1\nprint(l.count(0))']
|
['Runtime Error', 'Runtime Error', 'Accepted']
|
['s555752976', 's671445547', 's514855048']
|
[9176.0, 9184.0, 9184.0]
|
[23.0, 22.0, 24.0]
|
[143, 154, 152]
|
p02688
|
u350093546
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k=map(int,input().split())\nlist=[1:n+1]\nfor i in range(k):\n d=int(input())\n a=list(map(int,input.split()))\n list.remove(a)\nprint(count(list))', 'n,k=map(int,input().split())\nlst=[for _ in range(1,n+1)]\nfor i in range(k):\n x=int(input())\n a=list(map(int,input().split()))\n b=set(a)\n for j in b:\n lst.remove(j)\nprint(len(lst))', 'n,k=map(int,input().split())\nlst=[_ for _ in range(1,n+1)]\nfor i in range(k):\n x=int(input())\n a=list(map(int,input().split()))\n b=set(a)\n for j in b:\n if j in lst:\n lst.remove(j)\nprint(len(lst))']
|
['Runtime Error', 'Runtime Error', 'Accepted']
|
['s088799323', 's444053404', 's219554921']
|
[8952.0, 9000.0, 9136.0]
|
[22.0, 22.0, 23.0]
|
[146, 186, 207]
|
p02688
|
u357651829
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k=map(int,input().split())\nhashmap=dict()\nfor i in range(k):\n d=input()\n for i in range(d):\n key=int(input())\n hashmap[key]=d\ncount=0\nfor i in range(1,n+1):\n if hashmap.get(key)==None:\n count+=1\nprint(count)', 'n,k=map(int,input().split())\nhashmap=dict()\nfor i in range(k):\n d=int(input())\n for j in range(d):\n key=int(input())\n hashmap[key]=d\ncount=0\nfor i in range(1,n+1):\n if hashmap.get(i)==None:\n count+=1\nprint(count)', 'n,k=map(int,input().split())\nhashmap=dict()\nfor i in range(k):\n d=input()\n for i in range(d):\n key=int(input())\n hashmap[key]=d\n\ncount=0\nfor i in range(1,n+1):\n if hashmap.get(key)==None:\n count+=1\nprint(count)', 'n,k=map(int,input().split())\nhashmap=dict()\nfor i in range(k):\n d=int(input())\n for i in range(d):\n key=int(input())\n hashmap[key]=d\ncount=0\nfor i in range(1,n+1):\n if hashmap.get(i)==None:\n count+=1\nprint(count)', 'n,k=map(int,input().split())\nhashmap=dict()\nfor i in range(k):\n d=int(input())\n for i in range(d):\n key=int(input())\n hashmap[key]=d\ncount=0\nfor i in range(1,n+1):\n if hashmap.get(key)==None:\n count+=1\nprint(count)', 'n,k=map(int,input().split())\nhashmap=dict()\nfor _ in range(k):\n d=int(input())\n arr=[int(p) for p in input().split()]\n for key in arr:\n hashmap[key]=d\ncount=0\nfor i in range(1,n+1):\n if hashmap.get(i)==None:\n count+=1\nprint(count)']
|
['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted']
|
['s300425164', 's482138050', 's508933971', 's554318123', 's974115490', 's822902546']
|
[9204.0, 9192.0, 9192.0, 9192.0, 9204.0, 9188.0]
|
[20.0, 21.0, 23.0, 20.0, 24.0, 23.0]
|
[221, 224, 222, 224, 226, 240]
|
p02688
|
u363599046
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n, k = map(int,input().split())\nc = [0]*k\n\nfor i in range(k):\n\td = int(input())\n\tfor j in range(d):\n\t\td = list(map(int, input().split()))\n\t\tfor k in range(len(d)):\n\t\t\tc[d[k]] +=1\n\nprint(c.count(0))', 'n, k = map(int,input().split())\nc = [0]*n\n\nfor i in range(k):\n\td = int(input())\n\ta = list(map(int, input().split()))\n\tfor k in range(len(a)):\n\t\tc[a[k]-1] +=1\n\nprint(c.count(0))']
|
['Runtime Error', 'Accepted']
|
['s041493596', 's112541178']
|
[9100.0, 8992.0]
|
[24.0, 32.0]
|
[197, 176]
|
p02688
|
u369539054
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['import itertools\nn, k = map(int, input().split())\nd = []\na = []\nn_1=[i for i in range(1,n+1)]\nfor i in range(k):\n d.append(int(input()))\n a.append(list(map(int,input().split())))\na_1 = list(itertools.chain.from_iterable(a))\nc=list(set(n_1)-set(a_1))\nfor d in c:\n print(d)', "import itertools\nn, k = map(int, input().split())\nd = []\na = []\nn_1=[i for i in range(1,n+1)]\nfor i in range(k):\n d.append(int(input()))\n a.append(list(map(int,input().split())))\na_1 = list(itertools.chain.from_iterable(a))\nc=list(set(n_1)-set(a_1))\nif len(c)>1:\n c=' '.join(c)\n print(c)\nelse:\n print(c[0])\n ", 'import itertools\nn, k = map(int, input().split())\nd = []\na = []\nn_1=[i for i in range(1,n+1)]\nfor i in range(k):\n d.append(int(input()))\n a.append(list(map(int,input().split())))\na_1 = list(itertools.chain.from_iterable(a))\nc=list(set(n_1)-set(a_1))\nprint(len(c))\n ']
|
['Wrong Answer', 'Runtime Error', 'Accepted']
|
['s493465663', 's644699628', 's805348780']
|
[9212.0, 9032.0, 9220.0]
|
[25.0, 22.0, 23.0]
|
[278, 318, 272]
|
p02688
|
u373021729
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N,K = map(int, input().split())\nd = []\nn = []\nfor k in range(K):\n d.append(input())\n n.append(input().split())\ndef flatten(nested_list):\n return [e for inner_list in nested_list for e in inner_list]\nnfu = set(flatten(n))\nprint(nfu)\nprint(N - len(nfu))', 'N,K = map(int, input().split())\nd = []\nn = []\nfor k in range(K):\n d.append(input())\n n.append(input().split())\ndef flatten(nested_list):\n return [e for inner_list in nested_list for e in inner_list]\nnfu = set(flatten(n))\nprint(N - len(nfu))']
|
['Wrong Answer', 'Accepted']
|
['s058578126', 's684886457']
|
[9360.0, 9360.0]
|
[21.0, 21.0]
|
[260, 249]
|
p02688
|
u377834804
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N, K = map(int, input().split())\nsweet = [0 for i in range(N)]\nfor i in range(K):\n input()\n for j in map(int, input().split()):\n sweet[j] = 1\ncnt = 0\nfor k in sweet:\n if k == 0:\n cnt += 1\nprint(cnt)', 'N, K = map(int, input().split())\nsweet = [0 for i in range(N)]\nfor i in range(K):\n s = input()\n for j in map(int, input().split()):\n sweet[j-1] = 1\ncnt = 0\nfor k in sweet:\n if k == 0:\n cnt += 1\nprint(cnt)\n']
|
['Runtime Error', 'Accepted']
|
['s445195365', 's731840886']
|
[9172.0, 9152.0]
|
[22.0, 23.0]
|
[207, 214]
|
p02688
|
u379716238
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['import numpy as np\n\nN, K = list(map(int, input().split()))\nd = []\nA = []\nfor i in range(K):\n d.append(int(input()))\n A.append(list(map(int, input().split())))\n\nans = N - len(np.unique(A))\nprint(ans)', 'import numpy as np\n\nN, K = list(map(int, input().split()))\nd = []\nA = []\nfor i in range(K):\n d.append(int(input()))\n A.append(list(map(int, input().split())))\n\nA = sum(A, [])\nans = N - len(np.unique(A))\nprint(ans)']
|
['Wrong Answer', 'Accepted']
|
['s114450486', 's947444220']
|
[27348.0, 27436.0]
|
[104.0, 107.0]
|
[200, 215]
|
p02688
|
u381585104
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k = map(int,input().split())\nt = [0] * n\n\nfor _ in range(k):\n d = int(input())\n a = list(map(int,input().split()))\n\n for e in a:\n t[e-1] += 1\nans = 0\nl = [i for i in t if i != 0]\nprint(len(l))', 'n,k = map(int,input().split())\nt = [0] * n\n\nfor _ in range(k):\n d = int(input())\n a = list(map(int,input().split()))\n\n for e in a:\n t[e-1] += 1\nans = 0\nl = [i for i in t if i == 0]\n# print(l)\nprint(len(l))']
|
['Wrong Answer', 'Accepted']
|
['s914764820', 's175064346']
|
[9184.0, 9044.0]
|
[29.0, 30.0]
|
[210, 221]
|
p02688
|
u382407432
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N,K = map(int,(input().split()))\nn_list=[]\nans_list=[]\nfor i in range(N):\n ans_list.append(i+1)\n\nfor i in range(K):\n d = int(input())\n a_list = list(map(int, input().split()))\n n_list.extend(a_list)\n n_list = list(set(n_list))\nprint(*list(set(ans_list)-set(n_list)))', 'N,K = map(int,(input().split()))\nn_list=[]\nans_list=[]\nfor i in range(N):\n ans_list.append(i+1)\n\nfor i in range(K):\n d = int(input())\n a_list = list(map(int, input().split()))\n n_list.extend(a_list)\n n_list = list(set(n_list))\nprint(len(list(set(ans_list)-set(n_list))))']
|
['Wrong Answer', 'Accepted']
|
['s675040522', 's870314720']
|
[9204.0, 9192.0]
|
[22.0, 23.0]
|
[271, 275]
|
p02688
|
u390883247
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N,K = map(int,input().split())\nData = [0]*N\nprint(K)\nfor k in range(K):\n _ = input()\n user = list(map(int,input().split()))\n for u in user:\n Data[u-1] += 1\nans = 0\nfor i in range(N):\n if Data[i] == 0:\n ans += 1\nprint(ans)', 'N,K = map(int,input().split())\nData = [0]*N\nfor k in range(K):\n _ = input()\n user = list(map(int,input().split()))\n for u in user:\n Data[u-1] += 1\nans = 0\nfor i in range(N):\n if Data[i] == 0:\n ans += 1\nprint(ans)']
|
['Wrong Answer', 'Accepted']
|
['s238130639', 's433605488']
|
[9172.0, 9188.0]
|
[24.0, 23.0]
|
[247, 238]
|
p02688
|
u391675400
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k = map(int,input().split()) \nd = []\na = []\nfor i in range(k):\n d.append(int(input()))\n a.append(list(map(int,input().split())))\n\n\nsunuke =[0] * n\nfor i in range(k):\n #print("d[i]",d[i])\n for j in range(int(d[i])):\n temp = a[i][j] -1 \n sunuke[temp] += 1\n\nprint(sunuke)\nprint(sunuke.count(0))\n\n', 'n,k = map(int,input().split()) \nd = []\na = []\nfor i in range(k):\n d.append(int(input()))\n a.append(list(map(int,input().split())))\n\n\nsunuke =[0] * n\nfor i in range(k):\n #print("d[i]",d[i])\n for j in range(int(d[i])):\n temp = a[i][j] -1 \n sunuke[temp] += 1\n\n\nprint(sunuke.count(0))\n\n']
|
['Wrong Answer', 'Accepted']
|
['s993485928', 's089672406']
|
[9200.0, 9284.0]
|
[25.0, 25.0]
|
[334, 335]
|
p02688
|
u392058721
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n, k = map(int, input().split())\nc = 2 * k\nls = [input().split() for _ in range(c)]\ni = 1\nwhile i < c:\n l = [j for j in ls[i]]\n i += 2\nprint(n-len(set(l)))', 'n, k = map(int, input().split())\nc = 2 * k\nls = [input().split() for _ in range(c)]\ni = 1\nwhile i < c:\n l = [j for j in ls[i]]\n i += 2\nprint(n-len(sorted(l)))', 'n, k = map(int, input().split())\nc = 2 * k\nls = [input().split() for _ in range(c)]\ni = 1\nwhile i < c:\n l = [j for j in ls[i]]\n i += 1\nprint(n-len(sorted(l)))', 'n, k = map(int, input().split())\nc = 2 * k\nls = [input().split() for _ in range(c)]\ni = 1\nl = []\nwhile i < c:\n for j in ls[i]:\n l.append(j)\n i += 2\nprint(n-len(set(l)))']
|
['Wrong Answer', 'Wrong Answer', 'Wrong Answer', 'Accepted']
|
['s808700966', 's904898166', 's910304441', 's163756966']
|
[9596.0, 9348.0, 9520.0, 9352.0]
|
[24.0, 20.0, 24.0, 26.0]
|
[161, 164, 164, 181]
|
p02688
|
u394731058
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['3 3\n1\n3\n1\n3\n1\n3', "def main():\n ans = 0\n n,k = map(int, input(.split()))\n l = [0]*n\n for i in range(k):\n d = int(input())\n s = list(map(int, input().split()))\n for j in s:\n l[j-1] += 1\n for i in range(n):\n if l[i] == 0:\n ans += 1\n print(ans)\n\nif __name__ == '__main__':\n main()", "def main():\n ans = 0\n n,k = map(int, input().split())\n l = [0]*n\n for i in range(k):\n d = int(input())\n s = list(map(int, input().split()))\n for j in s:\n l[j-1] += 1\n for i in range(n):\n if l[i] == 0:\n ans += 1\n print(ans)\n\nif __name__ == '__main__':\n main()"]
|
['Runtime Error', 'Runtime Error', 'Accepted']
|
['s420116336', 's993170518', 's397188377']
|
[9008.0, 8948.0, 9208.0]
|
[22.0, 21.0, 22.0]
|
[15, 329, 329]
|
p02688
|
u402228762
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['a,b = map(int,input().split())\nlis = [0]*b\nfor i in range(a):\n c = int(input())\n d = input().split()\n \n for l in range(c):\n lis[int(d[l])-1] += 1\n \ncount = 0\nfor i in range(b):\n if(lis[i] == 0):\n count += 1\n\nprint(count)', 'a,b = map(int,input().split())\nlis = [0]*a\nfor i in range(b):\n c = int(input())\n d = input().split()\n \n for l in range(c):\n lis[int(d[l])-1] += 1\n \ncount = 0\nfor i in range(a):\n if(lis[i] == 0):\n count += 1\n\nprint(count)']
|
['Runtime Error', 'Accepted']
|
['s517958961', 's255760635']
|
[9132.0, 9204.0]
|
[23.0, 21.0]
|
[234, 234]
|
p02688
|
u405733072
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k = map(int,input().split())\na = [0]*n\nfor _ in range(k):\n kind = int(input())\n for i in list(map(int,input().split())):\n a[i-1] += 1\nprint(a.count(0) if 0 not in a else 0) \n ', 'n,k = map(int,input().split())\na = [0]*n\nfor _ in range(k):\n kind = int(input())\n for i in list(map(int,input().split())):\n a[i-1] += 1\nprint(a.count(0) if 0 in a else 0) ']
|
['Wrong Answer', 'Accepted']
|
['s744769824', 's469869585']
|
[9112.0, 9120.0]
|
[28.0, 28.0]
|
[193, 184]
|
p02688
|
u407513296
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k=map(int,input().split())\nans=[]\n\nfor i in range(k): \n d=int(input()) \n a=list(map(int,input().split()))\n for j in a: \n ans.append(1)\n\nprint(n-sum(ans)) \n #n-(0+1+1+1+0+0+...)\n', 'n,k=map(int,input().split())\nans=[0]*n \n\nfor i in range(k): \n d=int(input()) \n a=list(map(int,input().split()))\n for j in a: \n ans[j-1]=1 \n\nprint(n-sum(ans)) \n #n-(0+1+1+1+0+0+...)\n']
|
['Wrong Answer', 'Accepted']
|
['s016139947', 's910771819']
|
[9168.0, 9172.0]
|
[22.0, 24.0]
|
[395, 508]
|
p02688
|
u408375121
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n, k = map(int, input())\ntotal = set()\nfor _ in range(k):\n d = int(input())\n a = set(map(int, input().split()))\n for b in a:\n total.add(b)\nans = n - len(total)\nprint(ans)\n \n', 'n, k = map(int, input())\ntotal = set()\nfor _ in range(k):\n d = int(input())\n a = set(map(int, input().split()))\n total = total | a\nans = n - len(total)\nprint(ans)\n ', 'n, k = map(int, input())\ntotal = []\nfor _ in range(k):\n d = int(input())\n A = list(map(int, input().split()))\n for a in A:\n total.append(a)\nans = n - len(set(total))\nprint(ans)\n \n', 'n, k = map(int, input().split())\ntotal = []\nfor _ in range(k):\n d = int(input())\n A = list(map(int, input().split()))\n for a in A:\n total.append(a)\nans = n - len(set(total))\nprint(ans)\n \n']
|
['Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted']
|
['s541402029', 's666285558', 's780346145', 's838013801']
|
[9196.0, 9148.0, 9048.0, 9180.0]
|
[21.0, 23.0, 20.0, 21.0]
|
[180, 168, 186, 194]
|
p02688
|
u408958033
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k = int(input())\nf = []\nfor _ in range(k):\n x = int(input())\n l = list(map(int,input().split()))\n for i in range(len(l)):\n f.append(l[i])\nf = set(f)\nprint(n-len(f))', 'n,k = map(int,input().split())\nf = []\nfor _ in range(k):\n x = int(input())\n l = list(map(int,input().split()))\n for i in range(len(l)):\n f.append(l[i])\nf = set(f)\nprint(n-len(f))']
|
['Runtime Error', 'Accepted']
|
['s045336747', 's121537503']
|
[9188.0, 9120.0]
|
[20.0, 24.0]
|
[172, 184]
|
p02688
|
u414376763
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k = list(map(int,imput().split()))\nans = [1] * n\n\nfor i in range(k):\n d = int(input())\n for j in list(map(int,input().split())):\n ans[j-1] = 0\n\nprint(ans.count(1))', 'n,k = map(int,input().split())\noutput = []\n\nfor i in range(1,k):\n d = int(input())\n for j in range(1,d):\n output.append(int(input()))\n\nprint(n - len(set(output)))', 'n,k = map(int,input().split())\noutput = []\n\nfor i in range(k):\n d = int(input())\n l = list(map(int,input().split()))\n output.append(l)\n\nprint(n - len(set(output)))', 'n,k = map(int,input().split())\noutput = []\n\nfor i in range(k):\n d = int(input())\n for j in range(d):\n output.append(int(input()))\n\nprint(n - len(set(output)))', 'n,k = map(int,imput().split())\nans = [1] * n\n\nfor i in range(k):\n d = int(input())\n for j in list(map(int,input().split())):\n ans[j-1] = 0\n\nprint(ans.count(1))', 'n,k = map(int,input().split())\nans = [1] * n\n\nfor i in range(k):\n d = int(input())\n for j in list(map(int,input().split())):\n ans[j-1] = 0\n\nprint(ans.count(1))']
|
['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted']
|
['s029059097', 's707938968', 's742547926', 's838678313', 's895242956', 's035089020']
|
[9088.0, 9120.0, 9136.0, 9072.0, 9036.0, 9172.0]
|
[27.0, 24.0, 27.0, 25.0, 27.0, 28.0]
|
[170, 167, 166, 163, 164, 164]
|
p02688
|
u415875614
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N, K = map(int, input().split())\nD = []\ncount = 0\nsunuke_list = [0] * N\nprint(sunuke_list)\nfor j in range(K * 2):\n D = list(map(int, input().split()))\n if j % 2 == 1:\n for i in range(len(D)):\n sunuke_list[i - 1] = 1\n print(sunuke_list)\n\nprint(N - sum(sunuke_list))\n', 'N, K = map(int, input().split())\nsunuke_list = [1] * N\nfor j in range(K):\n D = int(input())\n D_list = list(map(int, input().split()))\n for i in D_list:\n sunuke_list[i - 1] = 0\nprint(sum(sunuke_list))']
|
['Wrong Answer', 'Accepted']
|
['s239481499', 's426701990']
|
[9212.0, 9188.0]
|
[26.0, 24.0]
|
[296, 205]
|
p02688
|
u418808418
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n, k = map(int, input().split())\n\nfor i in range(k):\n d[i] = int(input())\n a[i] = list(map(int, input().split()))\n\nfor i in range(n):\n if all((x == i for x in a)):\n print(i)', 'n, k = map(int, input().split())\n\nfor i in range(k):\n d[i] = int(input())\n a[i] = list(map(int, input().split()))\n\nfor i in range(n):\n if all((x != i for x in a)):\n print(i)', 'n, k = map(int, input().split())\n\nd = [0]*k\na = [0]*k\n\nfor i in range(k):\n d[i] = int(input())\n a[i] = list(map(int, input().split()))\n\nk = 0\n\nb = sum(a, [])\n \nfor i in range(n):\n if i+1 not in b:\n k = k + 1\n\nprint(k)']
|
['Runtime Error', 'Runtime Error', 'Accepted']
|
['s686216639', 's703051971', 's504514360']
|
[9184.0, 9188.0, 9208.0]
|
[21.0, 23.0, 24.0]
|
[189, 189, 236]
|
p02688
|
u423966555
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N, K = map(int, input().split())\n\ncheck = [0] * N\n\nfor i in range(K):\n d_i = int(input())\n A_i = map(int, input().split())\n for j in A_i:\n check[j] = 1\n\nprint(sum(1 for x in check if x == 0))\n', 'N, K = map(int, input().split())\n\ncheck = [0] * N\n\nfor i in range(K):\n d_i = int(input())\n A_i = map(int, input().split())\n for j in A_i:\n check[j-1] = 1\n\nprint(sum(1 for x in check if x == 0))\n']
|
['Runtime Error', 'Accepted']
|
['s661360641', 's230512523']
|
[9184.0, 9200.0]
|
[25.0, 23.0]
|
[208, 210]
|
p02688
|
u427514507
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N, K = (int(num) for num in input().split(" "))\ncnt = 0\ndic = {i+1: 0 for i in range(N)}\nprint(dic)\nwhile cnt < K:\n d = input()\n a = input().split(" ")\n for n in a:\n dic[int(n)] += 1\n cnt += 1\n\ntreated = 0\nfor key in dic:\n if dic[key] == 0:\n treated += 1\nprint(treated)\n', 'N, K = (int(num) for num in input().split(" "))\ncnt = 0\ndic = {i+1: 0 for i in range(N)}\nwhile cnt < K:\n d = input()\n a = input().split(" ")\n for n in a:\n dic[int(n)] += 1\n cnt += 1\n\ntreated = 0\nfor key in dic:\n if dic[key] == 0:\n treated += 1\nprint(treated)\n']
|
['Wrong Answer', 'Accepted']
|
['s205459108', 's216799510']
|
[9188.0, 9184.0]
|
[22.0, 21.0]
|
[299, 288]
|
p02688
|
u428785856
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['d=[];\nA=[];\nN,K=input().split();\nN=int(N);\nK=int(K);\nfor i in range(K):\n d.append(input())\n A.append(input().split());\nprint(A);\ncount=0;\nfor i in range(N):\n flag=0;\n for j in range(K):\n if(str(i+1) in A[j]):\n print(str(i+1)+" have "+str(A[j]));\n flag=1;\n if (flag == 0):\n count+=1;\n\nprint(count);', 'd=[];\nA=[];\nN,K=input().split();\nN=int(N);\nK=int(K);\nfor i in range(K):\n d.append(input())\n A.append(input().split());\ncount=0;\nfor i in range(N):\n flag=0;\n for j in range(K):\n if(str(i+1) in A[j]):\n flag=1;\n if (flag == 0):\n count+=1;\nprint(count);\n ']
|
['Wrong Answer', 'Accepted']
|
['s484726000', 's386026242']
|
[9548.0, 9532.0]
|
[103.0, 32.0]
|
[410, 360]
|
p02688
|
u429029348
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k=map(int,input().split())\ns=set()\nfor i in range(k):\n d=int(input())\n s=s|set(map(int,input().split()))\nprint(s)\nans=n-len(s)\nprint(ans)', 'n,k=map(int,input().split())\ns=set()\nfor i in range(k):\n d=int(input())\n a=set(map(int,input().split()))\n s=s|a\nans=n-len(s)\nprint(ans)\n ']
|
['Wrong Answer', 'Accepted']
|
['s207610846', 's175841892']
|
[9144.0, 9040.0]
|
[21.0, 21.0]
|
[141, 153]
|
p02688
|
u430336181
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N, K = input().split()\nd = []\nA = []\n\nfor _ in K:\n d.append(input())\n num = d[-1]\n for i in num:\n A.append(input())\n\nfor j in max(d)+1:\n if j+1 in A:\n pass\n else:\n print(j+1)\n\n', 'N, K = input().split()\nd = []\nA = []\nfor _ in K:\n d.append(int(input()))\n num = d[-1]\n for i in num:\n A.append(int(input()))\n\nfor j in max(d)+1:\n if j+1 in A:\n pass\n else:\n print(j+1)', 'N, K = map(int, input().split())\nuid_list = []\nfor _ in range(K):\n input()\n for uid in [int(i) for i in input().split()]:\n uid_list.append(uid)\nprint(N - len(set(uid_list)))']
|
['Runtime Error', 'Runtime Error', 'Accepted']
|
['s261939191', 's911589524', 's857040171']
|
[9124.0, 9188.0, 9192.0]
|
[23.0, 23.0, 24.0]
|
[212, 219, 183]
|
p02688
|
u430726059
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n, k = map(int, input().split())\n \nx = [0]*n\n \nfor i in range(k):\n d = int(input())\n a = list(map(int, input().split()))\n for j in a:\n x[j]=x[j]+1\nprint(x.count(0))', 'n, k = map(int, input().split())\n \nx = [0]*n\n \nfor i in range(k):\n d = int(input())\n a = list(map(int, input().split()))\n for j in a:\n x[j-1]=x[j-1]+1\nprint(x.count(0))']
|
['Runtime Error', 'Accepted']
|
['s641222578', 's213610567']
|
[9036.0, 9116.0]
|
[29.0, 26.0]
|
[178, 182]
|
p02688
|
u432253045
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
[" = [int(x) for x in input().split(' ')]\n \ndef solve(n, k):\n snukes = [None] * n\n victims = 0\n \n for i in range(k):\n snacks = int(input())\n snukes_snacks = [int(z) for z in input().split(' ')]\n for j in range(snacks):\n snukes[j-1] = snukes_snacks[j-1]\n \n for w in range(n):\n if snukes[w] is None:\n victims += 1\n \n print(victims)\n \nsolve(n, k)", "n,k = [int(x) for x in input().split(' ')]\n\ndef solve(n, k):\n snukes = [0] * n\n victims = 0\n\n for i in range(k):\n snacks = int(input())\n snukes_snacks = [int(z) for z in input().split(' ')]\n for j in range(snacks):\n snukes[j-1] = snukes_snacks[j-1]\n\n for w in range(n):\n if snukes[w] == 0:\n victims += 1\n \n print(snukes)\n print(victims)\n\nsolve(n, k)", "n,k = [int(x) for x in input().split(' ')]\n \ndef solve(n, k):\n snukes = [None] * n\n victims = 0\n \n for i in range(k):\n snacks = int(input())\n snukes_snacks = [int(z) for z in input().split(' ')]\n for j in range(snacks):\n snukes[snukes_snacks[j] - 1] = snukes_snacks[j]\n \n print(snukes)\n for w in range(n):\n if snukes[w] is None:\n victims += 1\n \n print(victims)\n \nsolve(n, k)", "n,k = [int(x) for x in input().split(' ')]\n \ndef solve(n, k):\n snukes = [None] * n\n victims = 0\n \n for i in range(k):\n snacks = int(input())\n snukes_snacks = [int(z) for z in input().split(' ')]\n for j in range(snacks):\n snukes[snukes_snacks[j] - 1] = snukes_snacks[j]\n \n for w in range(n):\n if snukes[w] is None:\n victims += 1\n \n print(victims)\n \nsolve(n, k)"]
|
['Runtime Error', 'Wrong Answer', 'Wrong Answer', 'Accepted']
|
['s279237709', 's370538179', 's401912757', 's206888784']
|
[9008.0, 9120.0, 9124.0, 9204.0]
|
[20.0, 23.0, 23.0, 23.0]
|
[409, 420, 451, 433]
|
p02688
|
u432453907
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N,K = input().split()\nd = input()\n\nprint(N-d)', 'N,K = map(int,input().split())\n\ns = []\n\nfor i in range(N):\n s.append(False)\n \nfor i in range(K):\n d = int(input())\n a = list(map(int,input().split()))\n for j in range(d):\n s[a[j]-1] = True\n \ncut = 0\nfor i in range(N):\n if not s[i]:\n cut += 1\n\nprint(cut)']
|
['Runtime Error', 'Accepted']
|
['s353206055', 's989143455']
|
[9024.0, 9124.0]
|
[22.0, 23.0]
|
[45, 292]
|
p02688
|
u436660228
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['total,okasi=map(int,input().split())\nsunuke=[]\n\nfor i in range(okasi):\n di=int(input)\n A=list(map(int,input().split()))\n for a in A:\n sunuke.append(input())\n \nprint(total-len(set(sunuke))) ', 'total,okasi=map(int,input().split())\nsunuke=[]\nfor i in range(okasi):\n d=int(input())\n A=list(map(int,input().split()))\n for a in A:\n sunuke.append(input())\n \n \nans=total-len(set(sunuke))\n \nprint(ans)', 'total,okasi=map(int,input().split())\nsunuke=[]\nfor i in range(okasi):\n d=int(input())\n A=list(map(int,input().split()))\n for a in A:\n sunuke.append(input())\n \n \nans=total-len(set(sunuke))\n\nprint(sunuke)\n \n \n \n ', 'total,okasi=map(int,input().split())\nsunuke=[]\nfor i in range(okasi):\n d=int(input())\n A=list(map(int,input().split()))\n for a in A:\n sunuke.append(a)\n \n \nans=total-len(set(sunuke))\n \nprint(ans)']
|
['Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted']
|
['s034589467', 's232854369', 's756919936', 's514027770']
|
[9184.0, 9160.0, 9148.0, 9184.0]
|
[21.0, 20.0, 22.0, 22.0]
|
[201, 212, 234, 206]
|
p02688
|
u444481227
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
["import numpy as np\n\nN =int(input(''))\nK=int(input(''))\nA=[]\nl=[]\nfor i in range(K):\n d = int(input(''))\n for j in range(d):\n l_ = int(input(''))\n l.append(l_)\n A.append(l)\n\na=np.zeros((N, K))\nfor i in range (len(A)):\n for j in range(len(A[i])):\n a[A[i][j]-1][i]=1\n#print(a)\n\nprint(np.count_nonzero(np.all(a==0, axis=1)))\n\n", "import numpy as np\n\nN,K=(int(x) for x in input().split())\n\nA=[]\nl=[]\nfor i in range(K):\n #d = int(input(''))\n #for j in range(d):\n #l_ = int(input(''))\n #l.append(l_)\n l=[int(x) for x in input().split()]\n A.append(l)\n\na=np.zeros((N, K))\nfor i in range (len(A)):\n for j in range(len(A[i])):\n a[A[i][j]-1][i]=1\n#print(a)\n\nprint(np.count_nonzero(np.all(a==0, axis=1)))\n", 'import numpy as np\n\nN,K=map(int, input().split())\n\nA=[]\nl=[]\nfor _ in range(K):\n d = map(int, input())\n l=list(map(int,input().split()))\n A.append(l)\n#print(A)\na=np.zeros((N, K))\nfor i in range (len(A)):\n for j in range(len(A[i])):\n a[A[i][j]-1][i]=1\n#print(a)\nprint(np.count_nonzero(np.all(a==0, axis=1)))\n']
|
['Runtime Error', 'Wrong Answer', 'Accepted']
|
['s222075890', 's827478658', 's953838005']
|
[26980.0, 27116.0, 27452.0]
|
[109.0, 113.0, 109.0]
|
[355, 402, 326]
|
p02688
|
u446185258
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n, k = map(int, input().split())\nate = set()\n\nfor i in range(k):\n d = int(input())\n l = list(map(int, input().split()))\n for x in l:\n ate.add(x)\nprint(ate)\nprint(n - len(ate))', 'n, k = map(int, input().split())\nate = set()\n\nfor i in range(k):\n d = int(input())\n l = list(map(int, input().split()))\n for x in l:\n ate.add(x)\n# print(ate)\nprint(n - len(ate))']
|
['Wrong Answer', 'Accepted']
|
['s302195514', 's540406021']
|
[9184.0, 9184.0]
|
[24.0, 21.0]
|
[191, 193]
|
p02688
|
u449580152
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k = map(int, input().split())\nA = []\nd = []\nfor i in range(k):\n d[i] = int(input())\n A[i] = list(map(int, input().split()))\n\nfor j in range(k):\n for k in range(d[j]):\n a = set(A[j][k])\n\nprint(n-len(a))', 'd = []\nA= []\nc = []\n \nfor i in range(k):\n d.append(int(input()))\n a = input()\n A.append([int(a[j]) for j in range(a)])\n \nfor j in range(k):\n for m in range(d[j]):\n c.append(A[j][m])\n \nprint(n-len(set(c)))', 'n,k = map(int, input().split())\nd = []\nA= []\nc = []\n \nfor i in range(k):\n d.append(int(input()))\n a = input()\n A.append([int(a[j]) for j in range(a)])\n \nfor j in range(k):\n for m in range(d[j]):\n c.append(A[j][m])\n \nprint(n-len(set(c)))', 'n,k = map(int, input().split())\nd = []\nA= []\nc = []\n\nfor i in range(k):\n d.append(int(input()))\n a = input()\n A.append([int(a[j]) for j in range(a)])\n\nfor j in range(k):\n for k in range(d[j]):\n c.append(A[j][k])\n\nprint(n-len(set(c)))', 'n,k = map(int, input().split())\nd = []\nc = []\ne = []\nfor i in range(k):\n d.append(int(input()))\n a = input()\n c.append([a[j:j+1] for j in range(len(a))])\n e[i] = list(map(int, c[i]))\n\nfor j in range(k):\n for k in range(d[j]):\n a = set(e[j][k])\n\nprint(n-len(a))', 'n,k = map(int, input().split())\nd = []\nA= []\nc = []\n \nfor i in range(k):\n d.append(int(input()))\n A.append(list(map(int, input().split())))\n \nfor j in range(k):\n for m in range(d[j]):\n c.append(A[j][m])\n \nprint(n-len(set(c)))']
|
['Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted']
|
['s275259906', 's559242057', 's623189925', 's670408410', 's732322837', 's222703965']
|
[9192.0, 9064.0, 9212.0, 9228.0, 9216.0, 9240.0]
|
[20.0, 22.0, 23.0, 21.0, 24.0, 22.0]
|
[219, 223, 255, 252, 282, 241]
|
p02688
|
u455133066
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['N,K=int(int(x) for x in input().split())\nlists=[0]*N\nwhile 1:\n tmp=int(input())\n if not tmp:\n break\n have_count=int(input().split())\n for i in have_count:\n lists[i-1]=1\nprint(lists.count(0))\n\n', 'N,K=(int(x) for x in input().split())\nlists=[0]*N\nwhile 1:\n tmp=int(input())\n if not tmp:\n break\n have_count=(int(x) for x in input().split())\n for i in have_count:\n lists[i-1]=1\nprint(lists.count(0))', 'N,K=int(input().split())\nlists=[0]*N\nwhile 1:\n tmp=int(input())\n if not tmp:\n break\n have_count=int(input().split())\n for i in have_count:\n lists[i-1]=1\nprint(lists.count(0))', 'N,K=(int(x) for x in input().split())\nlists=[0]*N\nwhile 1:\n try:\n tmp=int(input())\n except :\n break\n have_count=(int(x) for x in input().split())\n for i in have_count:\n lists[i-1]=1\nprint(lists.count(0))\n\n']
|
['Runtime Error', 'Runtime Error', 'Runtime Error', 'Accepted']
|
['s424477047', 's534848864', 's813203883', 's601048469']
|
[9104.0, 9192.0, 9084.0, 9128.0]
|
[25.0, 24.0, 23.0, 21.0]
|
[218, 226, 200, 238]
|
p02688
|
u455642216
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k=map(int,input().split())\nx=[0]*n\nfor i in range(k):\n y=int(input())\n z=list(map(int,input().split()))\n for j in z:\n x[j-1] +=1\na=0\nfor b in x:\n if b==0:\n c+=1\nprint(c)', 'n,k=map(int,input().split())\nx=[0]*n\nfor i in range(k):\n y=int(input())\n z=list(map(int,input().split()))\n for j in z:\n x[j-1] +=1\na=0\nfor b in x:\n if b==0:\n a+=1\nprint(a)']
|
['Runtime Error', 'Accepted']
|
['s478779979', 's891474898']
|
[9184.0, 9052.0]
|
[21.0, 22.0]
|
[197, 197]
|
p02688
|
u455957070
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['n,k = map(int, input().split())\ns = []\nans = 0\nrangecounter = 0\nfor i in range(k-1):\n d = int(input())\n rangecounter += d\n for j in range(d):\n s.append(input().split())\nfor i in range(rangecounter):\n if s.count(i) == 0:\n ans += 1\nprint(ans)', 'n , k = map(int,input().split())\nans = [0] * n\nfor i in range(k):\n d = int(input())\n for j in list(map(int,input().split())):\n ans[j-1] = 1\nprint(ans.count(0))\n']
|
['Runtime Error', 'Accepted']
|
['s584242868', 's740347822']
|
[9436.0, 9112.0]
|
[23.0, 20.0]
|
[250, 165]
|
p02688
|
u457437854
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
["x = input()\nn = int(x.split()[0])\nk = int(x.split()[1])\nmoji = ''\ncount = 0\n \nfor i in range(k * 2):\n s = input()\n if i % 2 != 0:\n moji = moji + s + ' '\nprint(moji)\nfor i in range(n):\n num = str(i+1)\n if moji.count(num):\n count\n else:\n count = count + 1\n \nprint(count)", 'n, k = map(int, input().split())\nlist = []\n\nfor i in range(k):\n dummy = int(input())\n ans = map(int, input().split())\n list.extend(ans)\n\nprint(n - len(set(list))) ']
|
['Wrong Answer', 'Accepted']
|
['s149260445', 's926311089']
|
[9192.0, 9228.0]
|
[23.0, 22.0]
|
[285, 167]
|
p02688
|
u457985479
| 2,000 | 1,048,576 |
N _Snukes_ called Snuke 1, Snuke 2, ..., Snuke N live in a town. There are K kinds of snacks sold in this town, called Snack 1, Snack 2, ..., Snack K. The following d_i Snukes have Snack i: Snuke A_{i, 1}, A_{i, 2}, \cdots, A_{i, {d_i}}. Takahashi will walk around this town and make mischief on the Snukes who have no snacks. How many Snukes will fall victim to Takahashi's mischief?
|
['[n,k] = map(int, input().split())\nSET = set()\nfor i in range(k):\n\td = int(input())\n tmp = set(map(int, input().split()))\n SET = (SET|tmp)\n\nprint(n-int(len(SET)))', '[n,k] = map(int, input().split())\nSET = set()\nfor i in range(k):\n d = int(input())\n tmp = set(map(int, input().split()))\n SET = (SET|tmp)\nprint(n-int(len(SET)))\n']
|
['Runtime Error', 'Accepted']
|
['s897256845', 's358309723']
|
[8932.0, 9104.0]
|
[21.0, 24.0]
|
[167, 164]
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.