結果
問題 |
No.1723 [Cherry 3rd Tune *] Dead on
|
ユーザー |
|
提出日時 | 2021-10-29 21:56:27 |
言語 | PyPy3 (7.3.15) |
結果 |
WA
|
実行時間 | - |
コード長 | 550 bytes |
コンパイル時間 | 496 ms |
コンパイル使用メモリ | 82,296 KB |
実行使用メモリ | 60,800 KB |
最終ジャッジ日時 | 2024-10-07 11:06:48 |
合計ジャッジ時間 | 4,424 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 48 WA * 2 |
ソースコード
from sys import exit from collections import defaultdict def Prime_factorization(x): result=defaultdict(int) if x==1: result[1]=1 return result i=2 while(i**2<=x): tmp=0 while(x%i==0): tmp+=1 x//=i if tmp>0: result[i]=tmp i+=1 if x>1: result[x]=1 return result x,a,y,b=map(int,input().split()) X=Prime_factorization(x) Y=Prime_factorization(y) for q,i in Y.items(): if X[q]*a<i*b: print("No") exit() print("Yes")