結果
| 問題 |
No.2954 Calculation of Exponentiation
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2024-11-08 21:50:06 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
RE
|
| 実行時間 | - |
| コード長 | 319 bytes |
| コンパイル時間 | 319 ms |
| コンパイル使用メモリ | 82,304 KB |
| 実行使用メモリ | 64,640 KB |
| 最終ジャッジ日時 | 2024-11-08 21:50:16 |
| 合計ジャッジ時間 | 2,755 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 RE * 1 |
| other | AC * 18 WA * 1 RE * 9 |
ソースコード
A,B=input().split()
x=int(A[:-5]+A[-4:])
y=10000
z=int(B[:-5]+B[-4:])
w=10000
if z<0:
x,y=y,x
z=-z
assert False
if x%y!=0:
print("No")
exit()
ans="No"
A=x//y
if A==1:
print("Yes")
exit()
for i in range(2,200000):
x=0
a=A
while a%i==0:
a//=i
x+=1
if a!=1:
continue
if (x*z)%w==0:
ans="Yes"
print(ans)