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

Home > Numbers
Three Digit Number(s) 2 (Posted on 2003-11-07) Difficulty: 3 of 5
Find a three digit number that fits the following criteria:

1)The digits are all different.
2)When each digit is squared and added together the number is the same as the number formed by the 2nd and 3rd digits in the number.
3)When the number formed by the last two digits is squared then added to (the first digit squared and added to itself) it is the same as the original number.

How many different three digit numbers are there that fit the criteria?

See The Solution Submitted by Lewis    
Rating: 3.5000 (6 votes)

Comments: ( Back to comment list | You must be logged in to post comments.)
Solution solution | Comment 1 of 5
I found only 420
with the following program:

#include <iostream.h>

int main(int argc, char* argv[])
{
  int a, b, c;

  for (a=1; a<10; a++)
  {
    for (b=0; b<10; b++)
    {
      for (c=0; c<10; c++)
      {
        if ( (a!=b) && (a!=c) && (b!=c) )
        {
          if ( ((a*a) + (b*b) + (c*c)) == (10*b + c) )
          {
            if ( ( ((10*b+c)*(10*b+c)) + (a*a + a)) == (100*a + 10*b + c) )
              cout << a << b << c << endl;
          }
        }
      }
    }
  }
  
  return 0;
}

  Posted by SilverKnight on 2003-11-07 15:13:58
Please log in:
Login:
Password:
Remember me:
Sign up! | Forgot password


Search:
Search body:
Forums (1)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (6)
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