結果

問題 No.610 区間賞(Section Award)
ユーザー pluto77pluto77
提出日時 2018-02-21 09:45:49
言語 Python2
(2.7.18)
結果
AC  
実行時間 221 ms / 2,000 ms
コード長 268 bytes
コンパイル時間 730 ms
コンパイル使用メモリ 6,492 KB
実行使用メモリ 17,784 KB
最終ジャッジ日時 2023-10-12 14:52:34
合計ジャッジ時間 5,913 ms
ジャッジサーバーID
(参考情報)
judge13 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 11 ms
5,844 KB
testcase_01 AC 11 ms
6,068 KB
testcase_02 AC 11 ms
5,932 KB
testcase_03 AC 10 ms
5,848 KB
testcase_04 AC 11 ms
5,952 KB
testcase_05 AC 10 ms
5,956 KB
testcase_06 AC 12 ms
6,016 KB
testcase_07 AC 12 ms
5,928 KB
testcase_08 AC 12 ms
6,044 KB
testcase_09 AC 12 ms
5,944 KB
testcase_10 AC 12 ms
5,928 KB
testcase_11 AC 12 ms
5,984 KB
testcase_12 AC 11 ms
6,100 KB
testcase_13 AC 12 ms
6,024 KB
testcase_14 AC 12 ms
6,144 KB
testcase_15 AC 12 ms
5,992 KB
testcase_16 AC 11 ms
5,996 KB
testcase_17 AC 12 ms
5,920 KB
testcase_18 AC 11 ms
5,956 KB
testcase_19 AC 36 ms
8,212 KB
testcase_20 AC 137 ms
17,348 KB
testcase_21 AC 27 ms
7,340 KB
testcase_22 AC 91 ms
13,472 KB
testcase_23 AC 20 ms
6,844 KB
testcase_24 AC 40 ms
8,596 KB
testcase_25 AC 18 ms
6,444 KB
testcase_26 AC 66 ms
11,060 KB
testcase_27 AC 133 ms
17,172 KB
testcase_28 AC 116 ms
15,856 KB
testcase_29 AC 86 ms
13,104 KB
testcase_30 AC 110 ms
15,136 KB
testcase_31 AC 60 ms
10,732 KB
testcase_32 AC 122 ms
16,416 KB
testcase_33 AC 26 ms
7,472 KB
testcase_34 AC 132 ms
17,256 KB
testcase_35 AC 67 ms
11,368 KB
testcase_36 AC 127 ms
16,732 KB
testcase_37 AC 107 ms
15,080 KB
testcase_38 AC 36 ms
8,328 KB
testcase_39 AC 137 ms
17,716 KB
testcase_40 AC 142 ms
17,728 KB
testcase_41 AC 137 ms
17,784 KB
testcase_42 AC 135 ms
17,708 KB
testcase_43 AC 140 ms
17,692 KB
testcase_44 AC 186 ms
15,328 KB
testcase_45 AC 220 ms
17,216 KB
testcase_46 AC 221 ms
17,516 KB
testcase_47 AC 115 ms
15,332 KB
testcase_48 AC 107 ms
15,048 KB
testcase_49 AC 116 ms
15,868 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#yuki610

n=int(raw_input())
a=map(int,raw_input().split())
b=map(int,raw_input().split())
m=[0 for i in xrange(n+1)]
for i,x in enumerate(a):
 m[x]=i
ma=-1
res=[]
for y in b:
 if ma<=m[y]:
  ma=m[y]
  res.append(y)
res.sort()
for i in xrange(len(res)):
 print res[i]
0