結果

問題 No.51 やる気の問題
ユーザー lrf141lrf141
提出日時 2016-12-04 00:58:50
言語 Java21
(openjdk 21)
結果
AC  
実行時間 124 ms / 5,000 ms
コード長 317 bytes
コンパイル時間 2,892 ms
コンパイル使用メモリ 74,272 KB
実行使用メモリ 41,320 KB
最終ジャッジ日時 2024-05-05 17:41:03
合計ジャッジ時間 6,305 ms
ジャッジサーバーID
(参考情報)
judge5 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 113 ms
41,188 KB
testcase_01 AC 118 ms
41,268 KB
testcase_02 AC 116 ms
40,920 KB
testcase_03 AC 117 ms
40,996 KB
testcase_04 AC 108 ms
40,520 KB
testcase_05 AC 102 ms
39,932 KB
testcase_06 AC 118 ms
41,136 KB
testcase_07 AC 120 ms
41,028 KB
testcase_08 AC 115 ms
41,052 KB
testcase_09 AC 122 ms
41,152 KB
testcase_10 AC 112 ms
40,728 KB
testcase_11 AC 114 ms
39,736 KB
testcase_12 AC 98 ms
39,440 KB
testcase_13 AC 112 ms
40,876 KB
testcase_14 AC 110 ms
40,760 KB
testcase_15 AC 115 ms
41,212 KB
testcase_16 AC 103 ms
39,988 KB
testcase_17 AC 120 ms
40,960 KB
testcase_18 AC 120 ms
41,196 KB
testcase_19 AC 115 ms
41,312 KB
testcase_20 AC 124 ms
40,944 KB
testcase_21 AC 112 ms
41,008 KB
testcase_22 AC 116 ms
41,320 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;
public class no52{
    public static void main(String... args){
        Scanner scan = new Scanner(System.in);
        int w = scan.nextInt();
        int d = scan.nextInt();

        while(d != 1){
            w -= (w/d/d);
            d--;
        }

        System.out.println(w);
    }
}
0