Algorithm to find Largest prime factor of a number
What is the best approach to calculating the largest prime factor of a number? I’m thinking the most efficient would be the following: Find lowest prime number that divides cleanly Check if result of division is prime If not, find next lowest Go to 2. I’m basing this assumption on it being easier to calculate … Read more