there is no need to iterate i from 1 to num, just to Math.sqrt(num),

because divisor larger or less than Math.sqrt(num) is Corresponding.

e.g like number 100,it's disivors are 1,2,4,5,10,20,25,50,100. the Math.sqrt(100) = 10, since divisors appear as pairs like(1,100),(2,50)

(4,25) (5,20) ,(10,10) ,so for number 100,iterating to 10 is enough.