結果
問題 |
No.56 消費税
|
ユーザー |
|
提出日時 | 2017-05-05 19:41:20 |
言語 | Java (openjdk 23) |
結果 |
AC
|
実行時間 | 55 ms / 5,000 ms |
コード長 | 500 bytes |
コンパイル時間 | 2,444 ms |
コンパイル使用メモリ | 74,376 KB |
実行使用メモリ | 50,528 KB |
最終ジャッジ日時 | 2024-09-14 08:44:24 |
合計ジャッジ時間 | 4,540 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge6 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 23 |
ソースコード
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(); } } }