結果

問題 No.714 回転寿司屋のシミュレート
ユーザー pluto77pluto77
提出日時 2018-07-26 18:50:07
言語 Python2
(2.7.18)
結果
AC  
実行時間 53 ms / 2,000 ms
コード長 347 bytes
コンパイル時間 298 ms
コンパイル使用メモリ 6,736 KB
実行使用メモリ 6,496 KB
最終ジャッジ日時 2023-09-13 18:45:06
合計ジャッジ時間 2,418 ms
ジャッジサーバーID
(参考情報)
judge11 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 13 ms
6,492 KB
testcase_01 AC 12 ms
6,496 KB
testcase_02 AC 13 ms
6,340 KB
testcase_03 AC 13 ms
6,244 KB
testcase_04 AC 16 ms
6,328 KB
testcase_05 AC 20 ms
6,324 KB
testcase_06 AC 29 ms
6,300 KB
testcase_07 AC 36 ms
6,324 KB
testcase_08 AC 53 ms
6,280 KB
testcase_09 AC 26 ms
6,212 KB
testcase_10 AC 23 ms
6,212 KB
testcase_11 AC 26 ms
6,284 KB
testcase_12 AC 24 ms
6,288 KB
testcase_13 AC 24 ms
6,324 KB
testcase_14 AC 25 ms
6,284 KB
testcase_15 AC 24 ms
6,292 KB
testcase_16 AC 25 ms
6,220 KB
testcase_17 AC 22 ms
6,324 KB
testcase_18 AC 24 ms
6,300 KB
testcase_19 AC 24 ms
6,476 KB
testcase_20 AC 23 ms
6,376 KB
testcase_21 AC 24 ms
6,480 KB
testcase_22 AC 19 ms
6,208 KB
testcase_23 AC 19 ms
6,440 KB
testcase_24 AC 19 ms
6,248 KB
testcase_25 AC 19 ms
6,228 KB
testcase_26 AC 18 ms
6,212 KB
testcase_27 AC 18 ms
6,440 KB
testcase_28 AC 19 ms
6,368 KB
testcase_29 AC 19 ms
6,204 KB
testcase_30 AC 13 ms
6,204 KB
testcase_31 AC 13 ms
6,280 KB
testcase_32 AC 13 ms
6,288 KB
testcase_33 AC 13 ms
6,288 KB
testcase_34 AC 12 ms
6,196 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#yuki714
from collections import Counter

n=int(raw_input())
l=[Counter() for i in xrange(20)]
for i in xrange(n):
 d=raw_input().split()
 if d[0]=='0':
  x=int(d[1])-1
  l[x]=Counter(d[3:])
 elif d[0]=='1':
  for j in xrange(20):
   if l[j][d[1]]>0:
    print j+1
    l[j][d[1]]-=1
    break
  else:
   print -1
 else:
  l[int(d[1])-1]=Counter()
0