Project Euler #231: The prime factorisation of binomial coefficients

  • + 0 comments

    Can someone give a hint to this? Sieving is too slow even for (10^9)/2 for it to be the right way. The case where k=1 is fine, but how can I solve larger k without knowing the large primes factor of nCm. Getting the product of all primes < N also slow. Is iterating fron k=1 up right? Or is it from from (n-m+1)C1 -> (n-m+2)C2 ->... nCm. Because of k, the problem is quiet different from project euler