結果
| 問題 | No.1250 汝は倍数なりや? | 
| コンテスト | |
| ユーザー |  nasubi24 | 
| 提出日時 | 2020-10-09 21:24:15 | 
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) | 
| 結果 | 
                                AC
                                 
                             | 
| 実行時間 | 157 ms / 1,000 ms | 
| コード長 | 249 bytes | 
| コンパイル時間 | 336 ms | 
| コンパイル使用メモリ | 12,544 KB | 
| 実行使用メモリ | 31,276 KB | 
| 最終ジャッジ日時 | 2024-07-20 08:15:05 | 
| 合計ジャッジ時間 | 4,314 ms | 
| ジャッジサーバーID (参考情報) | judge3 / judge2 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 3 | 
| other | AC * 49 | 
ソースコード
n,h=map(int,input().split())
a=list(map(int,input().split()))
cnt=a[0]%h
if cnt==0:
    ans=1
else:
    ans=0
for i in range(1,n):
    cnt*=a[i]
    cnt%=h
    if cnt==0:
        ans=1
        break
if ans==1:
    print("YES")
else:
    print("NO")
            
            
            
        