結果
問題 |
No.32 貯金箱の憂鬱
|
ユーザー |
![]() |
提出日時 | 2019-04-28 19:31:34 |
言語 | Java (openjdk 23) |
結果 |
AC
|
実行時間 | 71 ms / 5,000 ms |
コード長 | 602 bytes |
コンパイル時間 | 2,422 ms |
コンパイル使用メモリ | 77,332 KB |
実行使用メモリ | 38,244 KB |
最終ジャッジ日時 | 2024-07-23 07:32:57 |
合計ジャッジ時間 | 3,925 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 12 |
ソースコード
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.Arrays; public class Main { public static void main(String... args) throws IOException { try (BufferedReader reader = new BufferedReader(new InputStreamReader(System.in))) { int[] a = reader.lines().limit(3).mapToInt(Integer::parseInt).toArray(); int sum = (100 * a[0] + 25 * a[1] + a[2]) % 1000; int count = sum / 100; sum %= 100; count += sum / 25; System.out.println(count + sum % 25); } } }