結果

問題 No.647 明太子
ユーザー HimatsubushinHimatsubushin
提出日時 2022-02-01 15:11:09
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
TLE  
実行時間 -
コード長 563 bytes
コンパイル時間 173 ms
コンパイル使用メモリ 10,888 KB
実行使用メモリ 9,924 KB
最終ジャッジ日時 2023-09-02 02:31:00
合計ジャッジ時間 14,688 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 15 ms
7,896 KB
testcase_01 AC 15 ms
7,780 KB
testcase_02 AC 15 ms
7,888 KB
testcase_03 AC 15 ms
7,740 KB
testcase_04 AC 14 ms
7,912 KB
testcase_05 AC 16 ms
7,780 KB
testcase_06 AC 16 ms
7,796 KB
testcase_07 AC 17 ms
7,836 KB
testcase_08 AC 17 ms
7,816 KB
testcase_09 AC 51 ms
8,188 KB
testcase_10 AC 91 ms
8,344 KB
testcase_11 AC 32 ms
7,780 KB
testcase_12 AC 75 ms
8,344 KB
testcase_13 AC 159 ms
8,176 KB
testcase_14 AC 1,544 ms
9,464 KB
testcase_15 AC 222 ms
8,288 KB
testcase_16 AC 69 ms
8,228 KB
testcase_17 AC 2,014 ms
9,624 KB
testcase_18 AC 2,297 ms
9,600 KB
testcase_19 AC 588 ms
9,540 KB
testcase_20 AC 637 ms
9,220 KB
testcase_21 AC 242 ms
8,728 KB
testcase_22 TLE -
testcase_23 AC 18 ms
7,892 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

member = []
for _ in range(int(input())):
    a, b = map(int, input().split())
    member.append([a, b])
item = []
for _ in range(int(input())):
    a, b = map(int, input().split())
    item.append([a, b, 0])
max = 0
for [a, b] in member:
    for i in range(len(item)):
        x, y, z = item[i]
        if a >= x and b <= y:
            item[i] = [x, y, z + 1]
            if max < z + 1:
                max = z + 1
count = 0
if max == 0:
    print(0)
else:
    for i in range(len(item)):
        x, y, z = item[i]
        if z == max:
            print(i + 1)
0