結果

問題 No.722 100×100=1000
ユーザー
提出日時 2024-05-29 11:19:52
言語 Rust
(1.83.0 + proconio)
結果
WA  
実行時間 -
コード長 420 bytes
コンパイル時間 13,789 ms
コンパイル使用メモリ 392,044 KB
実行使用メモリ 6,820 KB
最終ジャッジ日時 2024-12-20 21:00:09
合計ジャッジ時間 15,349 ms
ジャッジサーバーID
(参考情報)
judge3 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 4
other AC * 21 WA * 6
権限があれば一括ダウンロードができます

ソースコード

diff #

fn main() {
	let mut s = String::new();
	std::io::stdin().read_line(&mut s).ok();
	let n: Vec<i64> = s.split_whitespace().flat_map(str::parse).collect();
	if n.iter().all(|x| {
		let mut x = x.abs();
		while x != 0 && x % 10 == 0 {
			x /= 10;
		}
		x > 0 && x < 10
	}) {
		println!("{}", n[0] * n[1] / 10);
		return;
	}
	let a = n[0] * n[1];
	if a.abs() < 100000000 {
		println!("{}", a)
	} else {
		println!("E")
	}
}
0