You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
AKS=(lambda n,m=__import__("math"):True if n==2 else False if n%2==0 else False if any(any(i**k==n for k in range(2,m.ceil(m.log(n,i))+1))for i in range(2,m.ceil(m.log2(n))+1))else(lambda r=(lambda l=m.log2(n):(lambda p=m.floor(l*l),q=max(3,m.ceil(l**5)):list(__import__('itertools').takewhile(lambda r:any(pow(n,k,r+1)in(0,1)for k in range(1,p)),range(1,q)))[-1]-1)())():True if n<=r else False if any(m.gcd(a,n)!=1 for a in range(1,r+1))else(lambda b=m.floor(m.sqrt(sum(m.gcd(i,r)==1 for i in range(1,r)))*m.log2(n)):not any(pow(a,n,n)-a!=0 for a in range(1,b+1)))())())