Factoring a Number
You can factor numbers with the factor command.
When called without specifying a value for the Number parameter, the factor command waits for you to enter a positive number less than 1E14 (100,000,000,000,000). It then writes the prime factors of that number to standard output. It displays each factor in order and the proper number of times if the same factor is used more than once. To exit, enter 0 (zero) or any non-numeric character.
When called with an argument, the factor command determines the prime factors of the Number parameter, writes the results to standard output, and exits.
The following is an example of how to calculate factors:
- To calculate the prime factors of the number 123, type:
factor 123 - Press Enter. The following displays:
123 3 41