Find the Factors of a Number

Tip: The algorithm iterates up to √n, which is highly efficient for standard numbers.