結果

問題 No.647 明太子
ユーザー MarioMario
提出日時 2018-05-15 15:23:08
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 2,280 ms / 4,500 ms
コード長 455 bytes
コンパイル時間 142 ms
コンパイル使用メモリ 10,776 KB
実行使用メモリ 10,596 KB
最終ジャッジ日時 2023-09-10 21:01:38
合計ジャッジ時間 8,465 ms
ジャッジサーバーID
(参考情報)
judge15 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 16 ms
7,784 KB
testcase_01 AC 16 ms
7,956 KB
testcase_02 AC 16 ms
7,864 KB
testcase_03 AC 15 ms
7,840 KB
testcase_04 AC 16 ms
7,864 KB
testcase_05 AC 16 ms
7,892 KB
testcase_06 AC 16 ms
7,980 KB
testcase_07 AC 17 ms
7,780 KB
testcase_08 AC 16 ms
7,804 KB
testcase_09 AC 34 ms
8,348 KB
testcase_10 AC 58 ms
8,356 KB
testcase_11 AC 27 ms
7,928 KB
testcase_12 AC 47 ms
8,364 KB
testcase_13 AC 88 ms
8,324 KB
testcase_14 AC 898 ms
10,264 KB
testcase_15 AC 124 ms
8,644 KB
testcase_16 AC 45 ms
8,248 KB
testcase_17 AC 1,139 ms
10,472 KB
testcase_18 AC 1,194 ms
10,376 KB
testcase_19 AC 409 ms
10,384 KB
testcase_20 AC 420 ms
10,008 KB
testcase_21 AC 148 ms
9,020 KB
testcase_22 AC 2,280 ms
10,596 KB
testcase_23 AC 21 ms
7,812 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n = int(input())
members = sorted([ list(map(int, input().split())) for _ in range(n)], key=lambda x:-x[0])
m = int(input())
mentaiko = [0] * m

for i in range(m):
    x, y = map(int, input().split())

    for price, hot in members:

        if x <= price and y >= hot:
            mentaiko[i] += 1

kiseki = sorted([i + 1 for i, x in enumerate(mentaiko) if x == max(mentaiko) and x != 0])
if kiseki == []:
    print(0)
else:
    print(*kiseki, sep="\n")
0