As several other questions have asked on this forum, how would you go about finding the factors of a number. 

Note: I have tried to understand what other people have written, please do not rehash already given answers

My code works as of right now but, for example the number 6 returns: 
6.0 factored by 1.0 is 6.000
6.0 factored by 2.0 is 3.000
6.0 factored by 3.0 is 2.000
6.0 factored by 4.0 is 1.500
6.0 factored by 5.0 is 1.200
6.0 factored by 6.0 is 1.000

Is there a way to remove all the decimal numbers?
I thought somehting about a "for" statement, but I don't really know how to use them.

Current Code:

```
public class Factoring {

public static void main(String[] args) {
    double input;
    double factor = 1;
    double factorNum;

    System.out.println("This application calculates every factor of a given number!"
            + "\nPlease enter a number: ");
    input = TextIO.getlnDouble();

    System.out.println("Original Number: " + input);

    while (input >= factor){
        factorNum = input / factor;

        System.out.print("\n" + input + " factored by " + factor + " is ");
        System.out.printf("%.3f", factorNum);
        factor++;
    }
}

}

```