Refactored 12 in terms of numDivisors.
Correct type signatures for divisors-related functions.