結果
問題 |
No.647 明太子
|
ユーザー |
|
提出日時 | 2018-03-29 10:37:33 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
AC
|
実行時間 | 2,623 ms / 4,500 ms |
コード長 | 744 bytes |
コンパイル時間 | 234 ms |
コンパイル使用メモリ | 12,672 KB |
実行使用メモリ | 12,800 KB |
最終ジャッジ日時 | 2024-06-27 02:54:04 |
合計ジャッジ時間 | 8,811 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 20 |
ソースコード
member = [] menta = [] # 10^4 n = int(input()) for _ in range(n): member.append(list(map(int, input().split()))) # 10^3 m = int(input()) for _ in range(m): menta.append(list(map(int, input().split()))) # print(member) # print(menta) # 10^3 * 10^4 numOfBuy = [] for index, (x, y) in enumerate(menta): # print('menta ', index, x, y) current = 0 for a, b in member: # print(f'member (yen, spice) = ({a}, {b})') if x <= a and b <= y: current += 1 numOfBuy.append(current) # print(f'{index} : menta = {current}') # print(numOfBuy) if max(numOfBuy) == 0: print(0) else: max = max(numOfBuy) for idx, num in enumerate(numOfBuy): if num == max: print(idx + 1)