結果
問題 | No.63 ポッキーゲーム |
ユーザー |
![]() |
提出日時 | 2016-02-24 02:59:16 |
言語 | Java (openjdk 23) |
結果 |
AC
|
実行時間 | 540 ms / 5,000 ms |
コード長 | 302 bytes |
コンパイル時間 | 2,233 ms |
コンパイル使用メモリ | 74,120 KB |
実行使用メモリ | 41,608 KB |
最終ジャッジ日時 | 2024-12-24 05:01:49 |
合計ジャッジ時間 | 7,621 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 22 |
ソースコード
import java.util.*; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int L = sc.nextInt(), K = sc.nextInt(); int cnt = 0; while(true) { cnt+=K * 2; if(cnt >= L) { System.out.println(cnt / 2 - K); break; } } } }