Skip to content

Instantly share code, notes, and snippets.

@lohxx
Last active March 7, 2018 22:13
Show Gist options
  • Save lohxx/8e3cefe29326f0806640da163771e1a4 to your computer and use it in GitHub Desktop.
Save lohxx/8e3cefe29326f0806640da163771e1a4 to your computer and use it in GitHub Desktop.
def ArmstrongNumbers(number):
return True if sum([int(x) ** len(str(number)) for x in str(number)]) == number else False
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment