Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def islejland(num):
- for x in range(1,10):
- for y in range(1,10):
- while True:
- if num == x**y + y**x:
- return True
- continue
- else:
- return False
- print(islejland(3))
- import math
- def isthreemorf(num):
- for x in range(1,1000):
- if num == math.pow(x, 3) and x == num[:-1]:
- return True
- continue
- isthreemorf(4)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement