結果
| 問題 | No.467 隠されていたゲーム |
| コンテスト | |
| ユーザー |
Mr.Fuku
|
| 提出日時 | 2018-07-21 12:03:12 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
AC
|
| 実行時間 | 39 ms / 2,000 ms |
| コード長 | 358 bytes |
| 記録 | |
| コンパイル時間 | 100 ms |
| コンパイル使用メモリ | 12,544 KB |
| 実行使用メモリ | 10,752 KB |
| 最終ジャッジ日時 | 2024-12-26 04:39:49 |
| 合計ジャッジ時間 | 2,135 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 24 |
ソースコード
import math
n = int(input())
step = [i for i in list(map(int,input().split()))]
goal = list(map(int,input().split()))
max_s = max(step)
max_g = max(abs(goal[0]),abs(goal[1]))
ans = 2
if max_s<=max_g:
ans = math.ceil(max_g/max_s)
elif max_g != 0:
for i in step:
if i==max_g:
ans = 1
break
else:
ans = 0
print(ans)
Mr.Fuku