結果

問題 No.647 明太子
ユーザー pete1288998pete1288998
提出日時 2020-06-27 19:04:22
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 3,276 ms / 4,500 ms
コード長 475 bytes
コンパイル時間 1,067 ms
コンパイル使用メモリ 10,888 KB
実行使用メモリ 9,952 KB
最終ジャッジ日時 2023-09-19 07:29:35
合計ジャッジ時間 10,622 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 16 ms
7,848 KB
testcase_01 AC 16 ms
7,940 KB
testcase_02 AC 16 ms
7,816 KB
testcase_03 AC 16 ms
7,848 KB
testcase_04 AC 16 ms
7,880 KB
testcase_05 AC 16 ms
7,872 KB
testcase_06 AC 16 ms
7,880 KB
testcase_07 AC 17 ms
7,840 KB
testcase_08 AC 17 ms
7,848 KB
testcase_09 AC 43 ms
8,372 KB
testcase_10 AC 73 ms
8,240 KB
testcase_11 AC 34 ms
7,840 KB
testcase_12 AC 61 ms
8,236 KB
testcase_13 AC 119 ms
8,332 KB
testcase_14 AC 1,103 ms
9,500 KB
testcase_15 AC 173 ms
8,332 KB
testcase_16 AC 58 ms
8,360 KB
testcase_17 AC 1,421 ms
9,600 KB
testcase_18 AC 1,537 ms
9,684 KB
testcase_19 AC 436 ms
9,456 KB
testcase_20 AC 468 ms
9,196 KB
testcase_21 AC 183 ms
8,636 KB
testcase_22 AC 3,276 ms
9,952 KB
testcase_23 AC 22 ms
7,800 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n = int(input())

mb = []
for i in range(n):
    a,b = map(int,input().split())
    mb.append([a,b])
    
m = int(input())

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

l = []
for i in range(m):
    cnt = 0
    for j in range(n):
        if c[i][0] <= mb[j][0] and c[i][1] >= mb[j][1]:
            cnt += 1
    l.append(cnt)

if max(l) == 0:
    print(0)
else:
    for i in range(len(l)):
        if l[i] == max(l):
            print(i+1)
0