Category: Loop
-
Given an integer, for each digit that makes up the integer determine whether it is a divisor. Count the number of divisors occurring within the integer.
Example Input => 124Check whether 1,2 and 4 are divisors of 124. All 3 numbers divide evenly into 124 so return 3. Input => 111Check whether 1,1 and 1 are divisors of 111. All 3 numbers divide evenly into 111 so return 3. Input => 10Check whether 1 and 0 are divisors of 10.1 is but 0 is…