Write a program that, given an int n, returns the number of unique factorizations of n

https://community.topcoder.com/stat?c=problem_statement&pm=2986&rd=5862

How to solve this in O(sqrt(n))