結果
| 問題 | No.9014 テストの合計点と平均点 |
| ユーザー |
|
| 提出日時 | 2023-07-26 02:22:24 |
| 言語 | Rust (1.97.1 + proconio + num + itertools + ACL) |
| 結果 |
WA
不安定
|
| 実行時間 | - |
| コード長 | 618 bytes |
| 記録 | |
| コンパイル時間 | 547 ms |
| コンパイル使用メモリ | 174,452 KB |
| 実行使用メモリ | 6,528 KB |
| 最終ジャッジ日時 | 2026-09-09 04:18:30 |
| 合計ジャッジ時間 | 1,723 ms |
|
ジャッジサーバーID (参考情報) |
judge2_0 / judge3_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | WA * 3 |
| other | WA * 3 |
ソースコード
fn main() {
// proconio使えないの厳しい...
// ref: https://doc.rust-jp.rs/atcoder-rust-resources/#素早く書くことにはあまり向かない仕様
let mut buf = String::new();
std::io::stdin().read_line(&mut buf).unwrap();
let mut iter = buf
.trim()
.split_terminator(',')
.map(|c| c.parse::<i32>().unwrap());
let (j, m, b) = (
iter.next().unwrap(),
iter.next().unwrap(),
iter.next().unwrap(),
);
let t = j + m + b;
let a: f64 = t as f64 / 3.0;
println!("合計点:{}", t);
println!("平均点:{:.1}", a);
}