@alvoutila,
To begin with, the factors of 120 are
2, 3, 4, 5, 6, 8, 10, 12, 15, 20, 24, 30, 40 and 60.
I'd suggest using a loop, initializing the index to 2 and stopping when the index
is equal to the number input.
Within the loop first divide input by the index and determine whether there
is no remainder (use modulo).
If there's no remainder, then save the index and the quotient in a list.
Also save the higher of the two numbers, replacing the previous higher
number.
As you continue to loop, you can break out of the loop once the index is equal
to the saved higher number.
At the end, sort the list in descending order and display it.