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

Home > Numbers
Double number digit sum (Posted on 2024-01-16) Difficulty: 3 of 5
N is the smallest positive integer such that the sum of the digits of N is 18 and the sum of the digits of 2N is 27. Find N.

No Solution Yet Submitted by Danish Ahmed Khan    
Rating: 4.0000 (1 votes)

Comments: ( Back to comment list | You must be logged in to post comments.)
Solution Computer solution | Comment 2 of 3 |
  N: 1449  1+4+4+9 = 18
 2N: 2898  2+8+9+8 = 27

--------------
def sod(n):
    """ Input an integer.  Returns the Sum of the Digits  """
    aList = list(str(n))
    ans = 0
    for c in aList:
        ans = ans + int(c)
    return ans

for n in range(10000):
    if sod(n) == 18 and sod(2*n) == 27:
        print('  N:',n, '\n', '2N:', 2*n)
        break

  Posted by Larry on 2024-01-16 08:21:56
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 (12)
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