結果

問題 No.647 明太子
ユーザー dnishdnish
提出日時 2018-07-27 17:17:32
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 2,783 ms / 4,500 ms
コード長 416 bytes
コンパイル時間 75 ms
コンパイル使用メモリ 10,860 KB
実行使用メモリ 9,752 KB
最終ジャッジ日時 2023-09-13 18:55:15
合計ジャッジ時間 9,368 ms
ジャッジサーバーID
(参考情報)
judge11 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 16 ms
7,844 KB
testcase_01 AC 16 ms
7,764 KB
testcase_02 AC 16 ms
7,800 KB
testcase_03 AC 17 ms
7,784 KB
testcase_04 AC 17 ms
7,936 KB
testcase_05 AC 17 ms
7,940 KB
testcase_06 AC 16 ms
7,864 KB
testcase_07 AC 16 ms
7,844 KB
testcase_08 AC 17 ms
7,848 KB
testcase_09 AC 40 ms
7,968 KB
testcase_10 AC 65 ms
8,308 KB
testcase_11 AC 27 ms
7,784 KB
testcase_12 AC 53 ms
8,220 KB
testcase_13 AC 103 ms
8,252 KB
testcase_14 AC 1,004 ms
9,488 KB
testcase_15 AC 148 ms
8,264 KB
testcase_16 AC 50 ms
8,188 KB
testcase_17 AC 1,281 ms
9,616 KB
testcase_18 AC 1,375 ms
9,424 KB
testcase_19 AC 421 ms
9,272 KB
testcase_20 AC 469 ms
9,200 KB
testcase_21 AC 178 ms
8,484 KB
testcase_22 AC 2,783 ms
9,752 KB
testcase_23 AC 17 ms
7,864 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
l = [tuple(map(int, input().split())) for i in range(N)]


M = int(input())
l1 = [tuple(map(int, input().split())) for i in range(M)]
ans = [0 for i in range(M)]

for i,(A, B) in enumerate(l):
    for j, (X, Y) in enumerate(l1):
        if X <= A and Y >= B:
            ans[j] += 1

K = max(ans)

if K == 0:
    print(0)
else:
    for i in range(M):
        if K == ans[i]:
            print(i + 1)
0