prime-factors exercise