Skip to content

Instantly share code, notes, and snippets.

@edalorzo
Created November 25, 2012 03:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save edalorzo/4142267 to your computer and use it in GitHub Desktop.
Save edalorzo/4142267 to your computer and use it in GitHub Desktop.
Project Euler-Problem #16
if __name__ == '__main__':
number = sum( [int(n) for n in str(2 ** 1000)] )
print "The sum of the digits of the number 2^1000 is: %d" % number
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment