SOLUTION: What is the largest 3-digit-number with the property that the number is equal to the sum of its hundreds digit, the squared of its 10 digit and the cube of its units digit?

Algebra ->  Customizable Word Problem Solvers  -> Numbers -> SOLUTION: What is the largest 3-digit-number with the property that the number is equal to the sum of its hundreds digit, the squared of its 10 digit and the cube of its units digit?      Log On

Ad: Over 600 Algebra Word Problems at edhelper.com


   



Question 891401: What is the largest 3-digit-number with the property that the number is equal to the sum of its hundreds digit, the squared of its 10 digit and the cube of its units digit?
Answer by richard1234(7193) About Me  (Show Source):
You can put this solution on YOUR website!
There isn't a really nice analytic solution other than casework on the units digit (which is still painfully time-consuming). I wrote a small Python program that checks all possibilities (add indentations):
def solve():
a = 1
b = 0
c = 0
for a in range(1, 10):
for b in range(0,10):
for c in range(0,10):
if 100*a + 10*b + c == a + b**2 + c**3:
print 100*a + 10*b + c
return None

The solutions are 135, 175, 518, and 598, the largest of which is 598.