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

Home > Numbers
Square = Square + Square (Posted on 2008-08-26) Difficulty: 3 of 5
Determine all 6 digit perfect squares such that the first three digits form a perfect square as do the last three.

The square formed by the first three digits may not have leading zeroes.

  Submitted by brianjn    
Rating: 2.5000 (4 votes)
Solution: (Hide)
256036  256  036
576081  576  081
144400  144  400
225625  225  625
324900  324  900
--------------------------------------------------
This was my program.  While its output was in the format
above, I did have to add the leading zeroes for 36 and 81.

OPEN "6sqr.txt" FOR OUTPUT AS #1
FOR a = 1 TO 31
  FOR b = 10 TO 31
      c= b^2*10^3 + a^3
	  IF sqr(c) = int(sqr(c))THEN
	     PRINT c, b^2, a^2
	     PRINT #1, c, b^2, a^2
	  ENDIF
  NEXT
NEXT
CLOSE 1

Comments: ( You must be logged in to post comments.)
  Subject Author Date
SolutionPuzzle SolutionK Sengupta2022-08-20 13:09:04
re(2): Solution - anDej Mar2008-08-26 23:41:21
re: Solution - an "imperfect" squarebrianjn2008-08-26 20:32:35
Solutioned bottemiller2008-08-26 13:35:36
SolutionSolutionDej Mar2008-08-26 13:25:32
Solutionre: Solution - brute forceCharlie2008-08-26 11:50:39
Solution - brute forceandre2008-08-26 11:15:47
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 (24)
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