I am a beginning Octave user and would like to compute all the integer divisors of a number, for example, for the number 120, I would like to get 1, 2, 3, 4, 5, 6, 8, 10, 12, 15, 20, 24, 30, 40, 60, and 120.
I know octave has the factor
function, but this only gives the prime factorization. I'd like all the integer divisors.