結果

問題 No.110 しましまピラミッド
ユーザー roiti46roiti46
提出日時 2015-02-10 18:44:56
言語 Python2
(2.7.18)
結果
WA  
実行時間 -
コード長 417 bytes
コンパイル時間 64 ms
コンパイル使用メモリ 6,704 KB
実行使用メモリ 6,140 KB
最終ジャッジ日時 2023-09-05 22:56:56
合計ジャッジ時間 1,605 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 AC 11 ms
5,992 KB
testcase_02 WA -
testcase_03 AC 11 ms
5,984 KB
testcase_04 AC 11 ms
5,984 KB
testcase_05 AC 11 ms
5,932 KB
testcase_06 AC 11 ms
5,856 KB
testcase_07 WA -
testcase_08 AC 11 ms
5,852 KB
testcase_09 WA -
testcase_10 WA -
testcase_11 WA -
testcase_12 AC 11 ms
5,916 KB
testcase_13 WA -
testcase_14 AC 11 ms
6,080 KB
testcase_15 WA -
testcase_16 WA -
testcase_17 WA -
testcase_18 WA -
testcase_19 AC 11 ms
6,060 KB
testcase_20 AC 11 ms
5,852 KB
testcase_21 AC 11 ms
5,980 KB
testcase_22 AC 11 ms
5,852 KB
testcase_23 WA -
testcase_24 WA -
testcase_25 AC 11 ms
5,848 KB
testcase_26 WA -
testcase_27 WA -
testcase_28 AC 11 ms
5,884 KB
testcase_29 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

Nw = int(raw_input())
W = list(set(map(int,raw_input().split())))
Nb = int(raw_input())
B = list(set(map(int,raw_input().split())))
WB = sorted([[w,"w"] for w in W] + [[b,"b"] for b in B])[::-1]

ans = 0
for sp in range(2):
    bar,col = WB[sp]
    tmp = 1
    for i,wb in WB[sp+1:]:
        if wb != col and i < bar:
            tmp += 1
            col = wb
            bar = i
    ans = max(ans,tmp)
print tmp
    
0