corrected things

after testing, completed program
added output for verification
undid last commit, as it fucked up the validity of the output
removed what I thought was a way to be more efficient (only going to
square root)
since a prime number, when divided in prime factors is a prime factor
(eg 13 = 13 (x1)), included that in output.