結果

問題 No.647 明太子
ユーザー nohakai3nohakai3
提出日時 2022-07-30 11:21:26
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 2,630 ms / 4,500 ms
コード長 346 bytes
コンパイル時間 167 ms
コンパイル使用メモリ 10,876 KB
実行使用メモリ 10,276 KB
最終ジャッジ日時 2023-09-27 13:27:11
合計ジャッジ時間 8,787 ms
ジャッジサーバーID
(参考情報)
judge11 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 13 ms
7,772 KB
testcase_01 AC 13 ms
7,924 KB
testcase_02 AC 14 ms
7,828 KB
testcase_03 AC 16 ms
7,864 KB
testcase_04 AC 15 ms
7,808 KB
testcase_05 AC 13 ms
7,780 KB
testcase_06 AC 13 ms
7,812 KB
testcase_07 AC 14 ms
7,800 KB
testcase_08 AC 16 ms
7,856 KB
testcase_09 AC 32 ms
7,892 KB
testcase_10 AC 61 ms
7,808 KB
testcase_11 AC 25 ms
7,836 KB
testcase_12 AC 48 ms
8,388 KB
testcase_13 AC 93 ms
8,332 KB
testcase_14 AC 813 ms
9,824 KB
testcase_15 AC 127 ms
8,252 KB
testcase_16 AC 45 ms
7,848 KB
testcase_17 AC 1,118 ms
9,932 KB
testcase_18 AC 1,236 ms
9,996 KB
testcase_19 AC 322 ms
9,960 KB
testcase_20 AC 341 ms
9,516 KB
testcase_21 AC 130 ms
8,520 KB
testcase_22 AC 2,630 ms
10,276 KB
testcase_23 AC 20 ms
7,812 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n=int(input())
l=[list(map(int,input().split())) for i in range(n)]
m=int(input())
c=[0]*m


for i in range(m):
    p,s=map(int,input().split())
    t=0
    for j in range(n):
        if p<=l[j][0] and s>=l[j][1]:
            t+=1
    c[i]=t

if sum(c)==0:
    print(0)
else:
    for i in range(m):
        if c[i]==max(c):
            print(i+1)
0