結果
| 問題 | No.1012 荷物収集 |
| コンテスト | |
| ユーザー |
ohara_n
|
| 提出日時 | 2020-03-20 22:07:41 |
| 言語 | Python3 (3.14.3 + numpy 2.4.4 + scipy 1.17.1) |
| 結果 |
TLE
|
| 実行時間 | - |
| コード長 | 253 bytes |
| 記録 | |
| コンパイル時間 | 539 ms |
| コンパイル使用メモリ | 20,568 KB |
| 実行使用メモリ | 15,232 KB |
| 最終ジャッジ日時 | 2026-05-25 19:14:06 |
| 合計ジャッジ時間 | 5,403 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 4 |
| other | TLE * 1 -- * 40 |
ソースコード
N,Q = map(int,input().split())
XW = []
for _ in range(N):
x, w = map(int,input().split())
XW.append((x,w))
Qs = list(map(int,input().split()))
for q in Qs:
cost = 0
for item in XW:
cost += abs(item[0] - q)*item[1]
print(cost)
ohara_n