結果

問題 No.128 お年玉(1)
ユーザー YatsukuYatsuku
提出日時 2015-12-15 19:53:52
言語 Java21
(openjdk 21)
結果
TLE  
実行時間 -
コード長 430 bytes
コンパイル時間 2,094 ms
コンパイル使用メモリ 79,292 KB
実行使用メモリ 64,648 KB
最終ジャッジ日時 2024-04-08 18:31:42
合計ジャッジ時間 10,089 ms
ジャッジサーバーID
(参考情報)
judge14 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 133 ms
57,960 KB
testcase_01 AC 132 ms
57,824 KB
testcase_02 AC 135 ms
57,984 KB
testcase_03 AC 282 ms
57,948 KB
testcase_04 AC 132 ms
57,936 KB
testcase_05 AC 133 ms
57,980 KB
testcase_06 AC 131 ms
57,964 KB
testcase_07 AC 131 ms
57,964 KB
testcase_08 AC 134 ms
57,956 KB
testcase_09 TLE -
testcase_10 -- -
testcase_11 -- -
testcase_12 -- -
testcase_13 -- -
testcase_14 -- -
testcase_15 -- -
testcase_16 -- -
testcase_17 -- -
testcase_18 -- -
testcase_19 -- -
testcase_20 -- -
testcase_21 -- -
testcase_22 -- -
testcase_23 -- -
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;


class No_128 {
	public static void main(String args[]) {
		Scanner stdIn = new Scanner(System.in);

		long budget = stdIn.nextLong();
		long persons = stdIn.nextLong();

		long count = 0;
		while ( true ) {
			if ( count * (persons * 1000) == budget ) {
				break;
			}
			if ( count * (persons * 1000) > budget ) {
				count--;
				break;
			}
			count++;
		}
		System.out.println(1000 * count);
	}
}
0