Advertisement
Guest User

Check Binary

a guest
Feb 22nd, 2017
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.24 KB | None | 0 0
  1. num = 100
  2. while num > 0:
  3. if int(num % 10 == 0):
  4. tempNum = num % 10
  5. num = int(num / 10)
  6. if num % 10 == tempNum % 10:
  7. print(True)
  8. else:
  9. print(False)
  10. else:
  11. print(False)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement