結果

問題 No.63 ポッキーゲーム
ユーザー tentententen
提出日時 2020-11-10 12:29:14
言語 Java21
(openjdk 21)
結果
AC  
実行時間 116 ms / 5,000 ms
コード長 286 bytes
コンパイル時間 2,028 ms
コンパイル使用メモリ 71,048 KB
実行使用メモリ 57,772 KB
最終ジャッジ日時 2023-09-29 23:27:45
合計ジャッジ時間 6,060 ms
ジャッジサーバーID
(参考情報)
judge11 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 106 ms
56,048 KB
testcase_01 AC 106 ms
56,228 KB
testcase_02 AC 107 ms
55,408 KB
testcase_03 AC 107 ms
56,044 KB
testcase_04 AC 110 ms
57,772 KB
testcase_05 AC 114 ms
55,776 KB
testcase_06 AC 116 ms
55,952 KB
testcase_07 AC 114 ms
56,164 KB
testcase_08 AC 108 ms
55,756 KB
testcase_09 AC 112 ms
55,500 KB
testcase_10 AC 110 ms
55,712 KB
testcase_11 AC 106 ms
56,056 KB
testcase_12 AC 105 ms
56,160 KB
testcase_13 AC 110 ms
55,868 KB
testcase_14 AC 111 ms
55,748 KB
testcase_15 AC 110 ms
55,812 KB
testcase_16 AC 108 ms
55,828 KB
testcase_17 AC 111 ms
55,672 KB
testcase_18 AC 108 ms
55,632 KB
testcase_19 AC 113 ms
55,944 KB
testcase_20 AC 106 ms
54,672 KB
testcase_21 AC 103 ms
55,884 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int length = sc.nextInt();
        int k = sc.nextInt();
        int count = (length - 1) / (k * 2);
        System.out.println(count * k);
    }
}
0