結果
| 問題 | No.32 貯金箱の憂鬱 |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2019-04-23 17:36:43 |
| 言語 | Rust (1.94.0 + proconio + num + itertools) |
| 結果 |
AC
|
| 実行時間 | 0 ms / 5,000 ms |
| + 937µs | |
| コード長 | 456 bytes |
| 記録 | |
| コンパイル時間 | 539 ms |
| コンパイル使用メモリ | 174,660 KB |
| 実行使用メモリ | 6,272 KB |
| 最終ジャッジ日時 | 2026-08-23 21:06:12 |
| 合計ジャッジ時間 | 2,128 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge3_1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 12 |
ソースコード
fn read<T: std::str::FromStr>() -> T {
let mut s = String::new();
std::io::stdin().read_line(&mut s).ok();
s.trim().parse().ok().unwrap()
}
fn main() {
let mut l: i32 = read();
let mut m: i32 = read();
let mut n: i32 = read();
if n >= 25 {
m += n / 25;
n = n % 25;
}
if m >= 4 {
l += m / 4;
m = m % 4;
}
if l >= 10 {
l = l % 10;
}
println!("{}", l + m + n);
}