Problem 615

A place to air possible concerns or difficulties in understanding ProjectEuler problems. This forum is not meant to publish solutions. This forum is NOT meant to discuss solution methods or giving hints how a problem can be solved.
Forum rules
As your posts will be visible to the general public you are requested to be thoughtful in not posting anything that might explicitly give away how to solve a particular problem.

This forum is NOT meant to discuss solution methods for a problem.

In particular don't post any code fragments or results.

Don't start begging others to give partial answers to problems

Don't ask for hints how to solve a problem

Don't start a new topic for a problem if there already exists one


See also the topics:
Don't post any spoilers
Comments, questions and clarifications about PE problems.
Post Reply
User avatar
beco
Posts: 4
Joined: Sat Dec 02, 2017 7:44 pm
Contact:

Problem 615

Post by beco »

Congratulations to the first 100!

I've tried, but due to lots of not so much prime factors, I couldn't!

I'm specially amused by the time achieved by the Japanese flag user uwi. Just 10 minutes!

That got me thinking...
User avatar
Jochen_P
Posts: 55
Joined: Mon Oct 05, 2009 10:47 am
Location: Stuttgart, Germany

Re: Problem 615

Post by Jochen_P »

Can someone confirm the 1000th number with at least 5 Prime Factors to be 9576 ?
thank you :)
Image
User avatar
hk
Administrator
Posts: 12832
Joined: Sun Mar 26, 2006 10:34 am
Location: Haren, Netherlands

Re: Problem 615

Post by hk »

This simple program tells you the answer:

Code: Select all

def primefactorcnt(n):
    res=0
    f=2
    while n>1:
        while n%f==0:
            n/=f
            res+=1
        f+=1
    return res
cnt=0
for n in xrange(2,10000):
    k=primefactorcnt(n)
    if k>=5:
        cnt+=1
        if cnt==1000:
            print n
            break
Image
War ruins the life and health of untold numbers of innocent children.
User avatar
Jochen_P
Posts: 55
Joined: Mon Oct 05, 2009 10:47 am
Location: Stuttgart, Germany

Re: Problem 615

Post by Jochen_P »

well, yeah, sure. Thanks :oops:
should've seen the ease of selftesting.

Now to find out where and why the easy to spot pattern from the example values breaks :(
Image
Post Reply