結果
| 問題 |
No.1250 汝は倍数なりや?
|
| コンテスト | |
| ユーザー |
cra77756176
|
| 提出日時 | 2022-12-23 18:51:50 |
| 言語 | Rust (1.83.0 + proconio) |
| 結果 |
AC
|
| 実行時間 | 36 ms / 1,000 ms |
| コード長 | 422 bytes |
| コンパイル時間 | 13,500 ms |
| コンパイル使用メモリ | 380,932 KB |
| 実行使用メモリ | 6,820 KB |
| 最終ジャッジ日時 | 2024-11-18 04:11:40 |
| 合計ジャッジ時間 | 12,426 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 49 |
ソースコード
fn main() {
let mut xx = String::new();
std::io::Read::read_to_string(&mut std::io::stdin(), &mut xx).ok();
let xx: Vec<i64> = xx.split_whitespace().flat_map(str::parse).collect();
let h = xx[1];
let mut product = 1;
for &x in &xx[2..] {
product *= x;
product %= h;
if product == 0 {
println!("YES");
return;
}
}
println!("NO");
}
cra77756176