If n is of the form p^r*q^s where p and q are primes, then all its divisors
will be of the form p^a*q^b where 0<=a<=r and 0<=b<=s
To get 4 perfect 5th power divisors, we choose a and b to be multiples of 5,
including 0. Then the smallest possible 4 perfect 5th power divisors would be:
p^0*q^0, p^0*q^5, p^5*q^0, and p^5*q^5
To get 6 perfect cube divisors, we choose a and b to be multiples of 3,
including 0. Then the smallest possible 6 perfect cube divisors would be
p^0*q^0, p^0*q^3, p^0*q^6, p^3*q^0, p^3*q^3, p^3*q^6
To get 12 perfect square divisors, we choose a and b to be multiples of 2,
including 0. Then the smallest possible 12 perfect square divisors would be
p^0*q^0, p^0*q^2, p^0*q^4, p^0*q^6, p^2*q^0, p^2*q^2, p^2*q^4, p^2*q^6,
p^4*q^0, p^4*q^2, p^4*q^4, p^4*q^6
The smallest way to get all those divisors is by chosing r=5 and s=6, i.e.,
n = p^5*q^6.
Since all divisors of p^5*q^6 are of the form p^a*q^b where
0<=a<=5 and 0<=b<=6, there are 6 choices for a and 7 choices for b.
That makes 6*7 or 42 divisors of n
Edwin