bash script to calculate all the factors for all numbers up to the number specified as a command-line argument