結果
問題 | No.32 貯金箱の憂鬱 |
ユーザー |
![]() |
提出日時 | 2016-05-09 16:04:23 |
言語 | Java (openjdk 23) |
結果 |
AC
|
実行時間 | 55 ms / 5,000 ms |
コード長 | 765 bytes |
コンパイル時間 | 2,273 ms |
コンパイル使用メモリ | 74,368 KB |
実行使用メモリ | 50,368 KB |
最終ジャッジ日時 | 2024-07-23 02:19:43 |
合計ジャッジ時間 | 3,331 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 12 |
ソースコード
/* package whatever; // don't place package name! */ import java.util.*; import java.lang.*; import java.io.*; /* Name of the class has to be "Main" only if the class is public. */ class Ideone { public static void main (String[] args) throws java.lang.Exception { // your code goes here BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); int sum = 0; sum += 100 * Integer.parseInt(br.readLine()); sum += 25 * Integer.parseInt(br.readLine()); sum += Integer.parseInt(br.readLine()); int coin = sum%1000; int ans = coin/100; coin = coin%100; ans += coin/25; coin = coin%25; ans += coin; System.out.println(ans); } }