Problem 539

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
Waldovski
Posts: 32
Joined: Thu Jul 08, 2010 11:11 am

Problem 539

Post by Waldovski »

I'm a little confused about how P(1000)=510. If I understand the procedure correctly, this is how n=100 is supposed to go:

2 4 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 36 38 40 42 44 46 48 50 52 54 56 58 60 62 64 66 68 70 72 74 76 78 80 82 84 86 88 90 92 94 96 98 100

2 6 10 14 18 22 26 30 34 38 42 46 50 54 58 62 66 70 74 78 82 86 90 94 98

6 14 22 30 38 46 54 62 70 78 86 94

6 22 38 54 70 86

22 54 86

22 86

86

According to the above procedure, P(100)=86 and P(1000)=342.

Did I misunderstand something? What am I doing wrong?
mdean
Posts: 206
Joined: Tue Aug 02, 2011 2:05 am

Re: Problem 539

Post by mdean »

Waldovski wrote: Sun Jan 15, 2017 10:38 am 22 54 86

22 86
I think everything looked good until this step, which is clearly wrong. Either the left-most or right-most (or possibly both) number gets removed each step. That clearly didn't happen here.
Image
Waldovski
Posts: 32
Joined: Thu Jul 08, 2010 11:11 am

Re: Problem 539

Post by Waldovski »

I'm an idiot. Thank you and apologies.
Post Reply