Finding the greatest factor
Add prime check and find largest prime factor
Change condition for max factor and target number