I need to find total numbers from 1 to 10000 whose product of digit is a perfect square.
eg: 49 (4*9=36), 236 ( 2*3*6=36) etc.
Till now i have figured out these things: 1) For a number to be a perfect square it must have even number of prime factors.
2)For a single digits factors possible are 1,2,3,5,7
hence if we are dealing with n digits we need to find total number of permutation for every digit such that there product will be in the form of even factors. eg: for 236 our digits are 2, 3 and 6. 6 can be factorized to 2X3. hence product of digits will become 2X3X2X3. for n= 1 2 3 4 ans is 4 30 312 3560
I understood the concept but i am unable to derive a formula for total permutations for n digits. Can you help me?