Find the smallest three distinct whole numbers A, B and C such that you can rearrange the digits of A and B to get C^2, the digits of A and C to get B^2, and the digits of B and C to get A^2.
**** Leading zeroes are not allowed.
(In reply to
better algorithm and answer again by Steven Lord)
Ty, SL.
I confirm having hyperlinked your methodology in the official solution.