結果

問題 No.477 MVP
ユーザー Takuya NoguchiTakuya Noguchi
提出日時 2018-03-17 12:44:53
言語 Ruby
(3.3.0)
結果
WA  
実行時間 -
コード長 163 bytes
コンパイル時間 280 ms
コンパイル使用メモリ 11,516 KB
実行使用メモリ 15,312 KB
最終ジャッジ日時 2023-08-25 15:38:52
合計ジャッジ時間 2,120 ms
ジャッジサーバーID
(参考情報)
judge14 / judge12
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 73 ms
15,288 KB
testcase_01 WA -
testcase_02 WA -
testcase_03 WA -
testcase_04 WA -
testcase_05 WA -
testcase_06 AC 74 ms
15,064 KB
testcase_07 AC 74 ms
15,056 KB
testcase_08 AC 72 ms
15,312 KB
testcase_09 AC 73 ms
15,200 KB
testcase_10 AC 71 ms
15,280 KB
testcase_11 AC 73 ms
15,196 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Syntax OK

ソースコード

diff #

N, K = gets.split.map(&:to_i)
minimum_damage = N.quo(K + 1)

if minimum_damage.denominator == 1
  puts minimum_damage.to_i
else
  puts minimum_damage.to_f.ceil
end
0