結果

問題 No.56 消費税
ユーザー jimanojimano
提出日時 2017-05-05 19:41:20
言語 Java21
(openjdk 21)
結果
AC  
実行時間 43 ms / 5,000 ms
コード長 500 bytes
コンパイル時間 3,157 ms
コンパイル使用メモリ 71,984 KB
実行使用メモリ 49,676 KB
最終ジャッジ日時 2023-10-12 09:49:53
合計ジャッジ時間 4,815 ms
ジャッジサーバーID
(参考情報)
judge11 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 42 ms
49,180 KB
testcase_01 AC 41 ms
49,316 KB
testcase_02 AC 41 ms
49,504 KB
testcase_03 AC 41 ms
49,064 KB
testcase_04 AC 41 ms
49,424 KB
testcase_05 AC 42 ms
49,288 KB
testcase_06 AC 42 ms
49,232 KB
testcase_07 AC 42 ms
49,600 KB
testcase_08 AC 42 ms
49,248 KB
testcase_09 AC 43 ms
49,132 KB
testcase_10 AC 41 ms
47,764 KB
testcase_11 AC 41 ms
49,168 KB
testcase_12 AC 41 ms
49,244 KB
testcase_13 AC 41 ms
49,240 KB
testcase_14 AC 42 ms
49,424 KB
testcase_15 AC 42 ms
49,604 KB
testcase_16 AC 41 ms
47,328 KB
testcase_17 AC 41 ms
49,608 KB
testcase_18 AC 41 ms
49,224 KB
testcase_19 AC 42 ms
49,312 KB
testcase_20 AC 42 ms
49,608 KB
testcase_21 AC 41 ms
49,216 KB
testcase_22 AC 42 ms
49,676 KB
testcase_23 AC 41 ms
49,248 KB
testcase_24 AC 41 ms
47,764 KB
testcase_25 AC 41 ms
49,128 KB
testcase_26 AC 41 ms
49,352 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main{
	public static void main(String[] args) {
		try (BufferedReader br = new BufferedReader(new InputStreamReader(System.in))) {
			String[] str = br.readLine().split(" ");
			int d = Integer.parseInt(str[0]);
			double p = (double)Integer.parseInt(str[1]) / 100;
			int price = (int) (d + (d * p));
			System.out.println(price);

		} catch (IOException e) {
			e.printStackTrace();
		}
	}
}
0