Solved the PrimeFactors challenge in Haskell