All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars    
perplexus dot info

Home > Just Math
Par Million Digit Sum Delight (Posted on 2024-06-20) Difficulty: 3 of 5
How many natural numbers less than one million have the sum of their digits equal to 12?

No Solution Yet Submitted by Danish Ahmed Khan    
No Rating

Comments: ( Back to comment list | You must be logged in to post comments.)
Solution Computer solution | Comment 1 of 3
6062
The smallest is 39 and the largest is 930000.

---------
sols = []
ct = 0
for n in range(1000001):
    if sod(n) == 12:
        ct += 1
        sols.append(n)
print(ct)
print(sols[0], sols[-1])

  Posted by Larry on 2024-06-20 07:54:38
Please log in:
Login:
Password:
Remember me:
Sign up! | Forgot password


Search:
Search body:
Forums (0)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (0)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

Chatterbox:
Copyright © 2002 - 2024 by Animus Pactum Consulting. All rights reserved. Privacy Information