結果
| 問題 |
No.1395 Less Sweet Alchemy
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2021-02-14 22:18:45 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 319 bytes |
| コンパイル時間 | 169 ms |
| コンパイル使用メモリ | 82,304 KB |
| 実行使用メモリ | 53,288 KB |
| 最終ジャッジ日時 | 2024-07-22 10:03:21 |
| 合計ジャッジ時間 | 1,451 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 8 WA * 4 |
ソースコード
from math import gcd
def lcm(x, y):
return (x * y) // gcd(x, y)
N,X = map(int,input().split())
C = list(map(int,input().split()))
lc = C[0]
for i in range(1,N):
lc = lcm(lc,C[i])
M = lc/X
if M.is_integer():
M = int(M)
if M >= N:
print("Yes")
else:
print("No")
else:
print("No")