Could anyone help me on finding all magic numbers using JAVA with 1000 iterations or less?
Magic numbers are 6 digit numbers that have the property that they are equal to the square of the sum of two 3-digit numbers when it's high-order and low-order digits are separated.
123789 is not a magic number because:
123+789 = 912 and 912^2 = 831744, which is not the original number 123789.
998001 is a magic number because:
998+1 = 999 and 999^2 = 998001, which is the original number.
Thank you in advance for your help.