結果

問題 No.647 明太子
ユーザー 👑 rin204rin204
提出日時 2020-08-20 01:21:19
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 429 bytes
コンパイル時間 143 ms
コンパイル使用メモリ 82,396 KB
実行使用メモリ 77,824 KB
最終ジャッジ日時 2024-04-20 16:41:41
合計ジャッジ時間 2,707 ms
ジャッジサーバーID
(参考情報)
judge3 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 35 ms
51,968 KB
testcase_01 AC 35 ms
52,480 KB
testcase_02 WA -
testcase_03 AC 35 ms
51,968 KB
testcase_04 AC 37 ms
51,968 KB
testcase_05 AC 35 ms
51,968 KB
testcase_06 AC 34 ms
52,480 KB
testcase_07 AC 42 ms
59,264 KB
testcase_08 AC 40 ms
59,776 KB
testcase_09 AC 52 ms
63,488 KB
testcase_10 AC 60 ms
66,944 KB
testcase_11 AC 58 ms
64,000 KB
testcase_12 AC 65 ms
67,968 KB
testcase_13 AC 75 ms
70,656 KB
testcase_14 AC 168 ms
77,184 KB
testcase_15 AC 90 ms
76,928 KB
testcase_16 AC 56 ms
66,048 KB
testcase_17 AC 203 ms
77,184 KB
testcase_18 AC 192 ms
77,256 KB
testcase_19 WA -
testcase_20 WA -
testcase_21 WA -
testcase_22 AC 168 ms
77,440 KB
testcase_23 AC 50 ms
63,360 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n = int(input())
ab = [list(map(int, input().split())) for _ in range(n)]
ans = []
max_cnt = -1
m = int(input())
for i in range(m):
    cnt = 0
    x, y = map(int, input().split())
    for a, b in ab:
        if x <= a and y >= b:
            cnt += 1
    if cnt > max_cnt:
        ans = [i + 1]
        max_cnt = cnt
    elif cnt == max_cnt:
        ans.append(i + 1)
if ans == []:
    print(0)
else:
    print(*ans, sep = "\n")
0