結果

問題 No.51 やる気の問題
ユーザー marumaru
提出日時 2016-03-22 22:46:09
言語 Java21
(openjdk 21)
結果
RE  
実行時間 -
コード長 295 bytes
コンパイル時間 3,864 ms
コンパイル使用メモリ 77,900 KB
実行使用メモリ 54,620 KB
最終ジャッジ日時 2024-04-09 03:26:11
合計ジャッジ時間 7,077 ms
ジャッジサーバーID
(参考情報)
judge3 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 128 ms
53,868 KB
testcase_01 AC 115 ms
52,812 KB
testcase_02 AC 128 ms
54,120 KB
testcase_03 AC 128 ms
54,076 KB
testcase_04 AC 129 ms
54,372 KB
testcase_05 RE -
testcase_06 AC 126 ms
54,108 KB
testcase_07 AC 115 ms
52,864 KB
testcase_08 AC 129 ms
54,004 KB
testcase_09 RE -
testcase_10 AC 128 ms
54,220 KB
testcase_11 AC 129 ms
54,248 KB
testcase_12 AC 130 ms
54,376 KB
testcase_13 AC 132 ms
54,100 KB
testcase_14 AC 131 ms
54,204 KB
testcase_15 RE -
testcase_16 AC 128 ms
54,372 KB
testcase_17 AC 128 ms
54,204 KB
testcase_18 RE -
testcase_19 RE -
testcase_20 AC 128 ms
54,088 KB
testcase_21 AC 114 ms
52,932 KB
testcase_22 RE -
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

public class yukicoder_51 {
	public static void main(String[] args) {
		Scanner stdIn = new Scanner(System.in);
		
		int w = stdIn.nextInt();
		int d = stdIn.nextInt();
		
		for (int i = d; i > 1; i--) {
			w = w - (w / (i * i));	
		}
		
		System.out.println(w);

	}
}
0