結果

問題 No.647 明太子
ユーザー kyo1
提出日時 2020-09-27 12:52:07
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
WA  
実行時間 -
コード長 387 bytes
コンパイル時間 116 ms
コンパイル使用メモリ 12,544 KB
実行使用メモリ 12,928 KB
最終ジャッジ日時 2024-06-30 11:58:16
合計ジャッジ時間 11,009 ms
ジャッジサーバーID
(参考情報)
judge2 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2 WA * 2
other AC * 18 WA * 2
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
AB = [list(map(int, input().split())) for _ in range(N)]
M = int(input())
XY = [list(map(int, input().split())) for _ in range(M)]

counts = [0 for _ in range(M)]

for i in range(N):
    for j in range(M):
        if AB[i][0] >= XY[j][0] and AB[i][1] <= XY[j][1]:
            counts[j] += 1

print(counts.index(max(counts)) + 1 if counts.index(max(counts)) != 0 else 0)
0