結果
問題 | No.446 ゆきこーだーの雨と雪 (1) |
ユーザー |
|
提出日時 | 2020-02-22 16:21:11 |
言語 | Rust (1.83.0 + proconio) |
結果 |
AC
|
実行時間 | 1 ms / 2,000 ms |
コード長 | 611 bytes |
コンパイル時間 | 12,174 ms |
コンパイル使用メモリ | 379,664 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-10-09 17:12:28 |
合計ジャッジ時間 | 13,245 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 13 |
ソースコード
fn main() {let mut a = String::new();std::io::stdin().read_line(&mut a).ok();let a: &str = a.trim();let mut b = String::new();std::io::stdin().read_line(&mut b).ok();let b: &str = b.trim();let mut ok: bool = true;ok &= a.parse::<usize>().is_ok()&& a.parse::<usize>().unwrap().to_string().len() == a.len()&& a.parse::<usize>().unwrap() <= 12345;ok &= b.parse::<usize>().is_ok()&& b.parse::<usize>().unwrap().to_string().len() == b.len()&& b.parse::<usize>().unwrap() <= 12345;println!("{}", if ok { "OK" } else { "NG" });}