結果
問題 |
No.9014 テストの合計点と平均点
|
ユーザー |
|
提出日時 | 2023-07-26 02:22:24 |
言語 | Rust (1.83.0 + proconio) |
結果 |
WA
|
実行時間 | - |
コード長 | 618 bytes |
コンパイル時間 | 11,740 ms |
コンパイル使用メモリ | 384,472 KB |
実行使用メモリ | 6,948 KB |
最終ジャッジ日時 | 2024-10-02 18:55:22 |
合計ジャッジ時間 | 12,550 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
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); }