結果

問題 No.110 しましまピラミッド
コンテスト
ユーザー titia
提出日時 2022-01-31 02:03:46
言語 Python3
(3.14.3 + numpy 2.4.4 + scipy 1.17.1)
コンパイル:
python3 -mpy_compile _filename_
実行:
python3 _filename_
結果
WA  
実行時間 -
コード長 266 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 358 ms
コンパイル使用メモリ 20,700 KB
実行使用メモリ 15,488 KB
最終ジャッジ日時 2026-03-04 10:43:30
合計ジャッジ時間 4,425 ms
ジャッジサーバーID
(参考情報)
judge1 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3 WA * 1
other AC * 18 WA * 8
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code

a=int(input())
W=list(map(int,input().split()))
b=int(input())
B=list(map(int,input().split()))

W=[(w,0) for w in W]
B=[(b,1) for b in B]

A=W+B
A.sort()

ANS=1

for i in range(1,len(A)):
    if A[i][0]!=A[i-1][0] and A[i][1]!=A[i-1][1]:
        ANS+=1

print(ANS)
0