結果

問題 No.51 やる気の問題
ユーザー Tsukasa_TypeTsukasa_Type
提出日時 2018-02-13 18:14:39
言語 Java21
(openjdk 21)
結果
AC  
実行時間 139 ms / 5,000 ms
コード長 250 bytes
コンパイル時間 2,183 ms
コンパイル使用メモリ 73,976 KB
実行使用メモリ 41,708 KB
最終ジャッジ日時 2024-05-07 09:53:30
合計ジャッジ時間 6,225 ms
ジャッジサーバーID
(参考情報)
judge2 / judge3
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 133 ms
41,252 KB
testcase_01 AC 132 ms
41,460 KB
testcase_02 AC 135 ms
41,288 KB
testcase_03 AC 134 ms
41,008 KB
testcase_04 AC 134 ms
41,596 KB
testcase_05 AC 137 ms
41,124 KB
testcase_06 AC 135 ms
41,212 KB
testcase_07 AC 136 ms
41,240 KB
testcase_08 AC 136 ms
41,596 KB
testcase_09 AC 138 ms
41,212 KB
testcase_10 AC 127 ms
39,804 KB
testcase_11 AC 136 ms
41,168 KB
testcase_12 AC 136 ms
41,260 KB
testcase_13 AC 139 ms
41,708 KB
testcase_14 AC 131 ms
41,392 KB
testcase_15 AC 135 ms
41,472 KB
testcase_16 AC 133 ms
41,344 KB
testcase_17 AC 137 ms
41,004 KB
testcase_18 AC 136 ms
41,116 KB
testcase_19 AC 134 ms
41,584 KB
testcase_20 AC 133 ms
41,460 KB
testcase_21 AC 134 ms
41,304 KB
testcase_22 AC 137 ms
41,600 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;

public class Main {
	static Scanner sc = new Scanner(System.in);
	public static void main(String[] args) {
		int w = sc.nextInt();
		int d = sc.nextInt();
		while (d > 1) {
			w -= w/d/d;
			d--;
		}
		System.out.println(w);
	}
}
0