結果
| 問題 |
No.1722 [Cherry 3rd Tune C] In my way
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2021-10-29 22:10:16 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
AC
|
| 実行時間 | 54 ms / 2,000 ms |
| コード長 | 327 bytes |
| コンパイル時間 | 343 ms |
| コンパイル使用メモリ | 82,380 KB |
| 実行使用メモリ | 63,616 KB |
| 最終ジャッジ日時 | 2024-10-07 11:29:26 |
| 合計ジャッジ時間 | 2,264 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 23 |
ソースコード
from bisect import bisect_right
N,M = map(int,input().split())
X = list(map(int,input().split()))
Y = list(map(int,input().split()))
Y.sort()
ANS = []
for x in X:
index = bisect_right(Y,x)
if index == M:
ANS.append('Infinity')
else:
ANS.append(Y[index] - x)
for ans in ANS:
print(ans)