結果

問題 No.110 しましまピラミッド
ユーザー ああいいああいい
提出日時 2021-12-24 18:11:07
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
WA  
実行時間 -
コード長 358 bytes
コンパイル時間 113 ms
コンパイル使用メモリ 11,840 KB
実行使用メモリ 10,120 KB
最終ジャッジ日時 2023-10-19 21:00:11
合計ジャッジ時間 2,051 ms
ジャッジサーバーID
(参考情報)
judge15 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 AC 32 ms
10,120 KB
testcase_02 AC 29 ms
10,120 KB
testcase_03 AC 29 ms
10,120 KB
testcase_04 AC 30 ms
10,120 KB
testcase_05 AC 29 ms
10,120 KB
testcase_06 AC 30 ms
10,120 KB
testcase_07 AC 30 ms
10,120 KB
testcase_08 AC 29 ms
10,120 KB
testcase_09 AC 29 ms
10,120 KB
testcase_10 AC 31 ms
10,120 KB
testcase_11 AC 30 ms
10,120 KB
testcase_12 AC 30 ms
10,120 KB
testcase_13 WA -
testcase_14 AC 29 ms
10,120 KB
testcase_15 WA -
testcase_16 AC 29 ms
10,120 KB
testcase_17 WA -
testcase_18 AC 30 ms
10,120 KB
testcase_19 AC 30 ms
10,120 KB
testcase_20 AC 30 ms
10,120 KB
testcase_21 AC 30 ms
10,120 KB
testcase_22 AC 29 ms
10,120 KB
testcase_23 AC 29 ms
10,120 KB
testcase_24 AC 30 ms
10,120 KB
testcase_25 AC 30 ms
10,120 KB
testcase_26 WA -
testcase_27 WA -
testcase_28 AC 30 ms
10,120 KB
testcase_29 AC 30 ms
10,120 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
l = list(map(int,input().split()))
M = int(input())
s = list(map(int,input().split()))
w = [(i,0) for i in l]
b = [(i,1) for i in s]
l = w + b
l.sort(reverse = True)
i = 0
ans = 0
while i < len(l):
    flag = l[i][1]
    length = l[i][0]
    ans += 1
    while i < len(l) and (l[i][1] == flag or l[i][0] == length):
        i += 1
print(ans)
0