Dear All,
I'm writing a program to factorize an integer into 2 factors only. for example, the prime factorization for 24 is: 2,2,2,3, but what I want the output to be only 4 and 6. another example, 42: 2,3,7 but my what I want the output to be is 6 and 7. where 6 comes from the multiplications of the two smallest factors: 2X3 and I do not want the results to be 2 and 21 where 21 comes from the multiplications of 3 and 7. in other words , the output must indicates find the smallest two integers for a list of factors of an integer.
another example 60: 2,2,3,5
the output I want it is 2x3 and 2x5 = 6,10 = 16
and not 2x2 and 3X5 = 4,15 = 19
because 16 is less than 19 and this is what I want actually.