dxnge

tsk 16

Nov 12th, 2021
107
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.34 KB | None | 0 0
  1. def progres(x, y):
  2.     if x+10 == y:
  3.         return True
  4.     return False
  5.  
  6.  
  7. for i in range(854_321, 1_087_654):
  8.     dls = set()
  9.     for d in range(2, int(i**0.5)+1):
  10.         if i % d == 0:
  11.             dls |= {d, i//d}
  12.     if all(progres(x[0], x[1]) for x in zip(sorted(dls), sorted(dls)[1:])) and len(dls) > 1:
  13.         print(i, min(dls))
  14.  
Advertisement
Add Comment
Please, Sign In to add comment