Paul Rubin <no.email at nospam.invalid> writes: > ... d = gcd(abs(x-y), n) ... > print pollard(2778562183799360736577L) > finds the factor 25781083 almost instantly. > Whoops, you need this too: def gcd(x,y): while True: x,y = y,x%y if y==0: return x