結果
問題 |
No.8062 A + B
|
ユーザー |
![]() |
提出日時 | 2020-04-01 21:37:26 |
言語 | Rust (1.83.0 + proconio) |
結果 |
WA
|
実行時間 | - |
コード長 | 475 bytes |
コンパイル時間 | 13,206 ms |
コンパイル使用メモリ | 379,820 KB |
実行使用メモリ | 5,376 KB |
最終ジャッジ日時 | 2024-06-27 09:47:47 |
合計ジャッジ時間 | 13,462 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 7 WA * 1 |
ソースコード
fn run() { let mut s = String::new(); std::io::stdin().read_line(&mut s).unwrap(); let mut it = s.trim().split_whitespace(); let a: i128 = it.next().unwrap().parse().unwrap(); let b: i128 = it.next().unwrap().parse().unwrap(); if b < 0 { println!("{}", a + b); } else { let mut m = 10; while m <= b { m *= 10; } let ans = m * a + b; println!("{}", ans); } } fn main() { run(); }