結果
| 問題 |
No.1250 汝は倍数なりや?
|
| コンテスト | |
| ユーザー |
nak2yoshi
|
| 提出日時 | 2020-10-09 22:53:05 |
| 言語 | D (dmd 2.109.1) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 321 bytes |
| コンパイル時間 | 1,659 ms |
| コンパイル使用メモリ | 174,392 KB |
| 実行使用メモリ | 12,136 KB |
| 最終ジャッジ日時 | 2024-06-22 09:23:48 |
| 合計ジャッジ時間 | 3,693 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 35 WA * 14 |
ソースコード
import std;
void main() {
auto input = readln.split.to!(int[]);
auto N = input[0], H = input[1];
auto A = readln.split.to!(int[]);
long P = 1;
foreach (i; 0 .. N) {
P *= A[i];
if (abs(P) % H == 0) {
writeln("YES");
return;
}
}
writeln("NO");
}
nak2yoshi