Page 1 of 1
Problem 120
Posted: Thu Oct 22, 2009 10:06 pm
by bobfin
Apoplogies for posting on a relatively old problem but I've only recently discovered the site. Could anyone provide some feedback on problem 120. I thought I had a suitable algorithm which correctly calculates the a = 7, rmax = 42 example provided. However my total is incorrect. Hoping this doesn't breach your guidelines re-solutions, could anyone confirm that these early values are correct:
a = 3 rmax = 6
a = 4 rmax = 8
a = 5 rmax = 10
a = 6 rmax = 12
a = 7 rmax = 42
a = 8 rmax = 48
a = 9 rmax = 54
a = 10 rmax = 60
a = 11 rmax = 110
a = 12 rmax = 120
a = 13 rmax = 130
a = 14 rmax = 140
a = 15 rmax = 210
Re: Problem 120
Posted: Thu Oct 22, 2009 11:14 pm
by daniel.is.fischer
55+75 [cong] 24 (mod 36).
Re: Problem 120
Posted: Mon Oct 26, 2009 4:22 am
by bobfin
Thanks that helped. Solved now.
Re: Problem 120
Posted: Sat Jun 26, 2010 10:27 am
by SJ_Mufasa
what's the range that the n value can have??
Re: Problem 120
Posted: Sat Jun 26, 2010 11:02 am
by SJ_Mufasa
what's this question asking exactly?
is it asking for the sum of all the rmax values for a in range2<a<1001
so 6 + 8 + 10 + 24 + 42 + 48....until it reaches the rmax for a=100?
Re: Problem 120
Posted: Sat Jun 26, 2010 11:40 am
by harryh
SJ_Mufasa wrote:what's the range that the n value can have??
None is specified by the problem, so
n can take any (positive) integer value.
what's this question asking exactly?
is it asking for the sum of all the rmax values for a in range2<a<1001
so 6 + 8 + 10 + 24 + 42 + 48....until it reaches the rmax for a=100?
Yes, up to a=100
0.
Re: Problem 120
Posted: Sun Jun 27, 2010 1:37 am
by SJ_Mufasa
oh, thanks very much, finally solved now =]
Re: Problem 120
Posted: Sat Sep 25, 2010 12:33 am
by frogboy77
need help
is this true
when
a=5; rmax=20 when n=7
?
looking at previous posts it doesn't look promising both showing 10
its late maybe me being dumb
p.s can this problem be done in ULL range?
sorry mean 64bit int range
Re: Problem 120
Posted: Sat Sep 25, 2010 2:42 am
by jaap
frogboy77 wrote:a=5; rmax=20 when n=7
Correct.
frogboy77 wrote:p.s can this problem be done in ULL range?
sorry mean 64bit int range
It can quite comfortably be done in 32 bit range too.
Problem 120 - I think correct answer is incorrect
Posted: Mon Aug 08, 2011 9:01 am
by oleglyamin
I'm kinda struggling with how to describe an error without hinting at how the problem should be solved...
But the answer which project euler takes as correct one assumes that the maximum remainder for, say, a = 705 is r = 496320. In fact, it's 494910.
Please, check.
Re: Problem 120 - I think correct answer is incorrect
Posted: Mon Aug 08, 2011 9:33 am
by thedoctar
You are not supposed to create new threads about a problem. You probably didn't know this cause you're new, but please post your problem in this thread:
Problem 120. If you have a problem on a problem, search the forum for "Problem xxx", where xxx is the problem number. There will already be an existing thread there.
An admin will probably delete this thread or something.
Also, the answers to problems are never wrong. Problem 120 can be solved through analysis. I solved it through pen/paper, didn't even need a program!
Re: Problem 120 - I think correct answer is incorrect
Posted: Mon Aug 08, 2011 9:45 am
by hk
oleglyamin wrote:I'm kinda struggling with how to describe an error without hinting at how the problem should be solved...
But the answer which project euler takes as correct one assumes that the maximum remainder for, say, a = 705 is r = 496320. In fact, it's 494910.
Please, check.
From the Project Euler about page:
I've checked my program ten times now and I keep getting told my answer is wrong! Have you made a mistake?
With newly released problems it is quite possible that a small error may have slipped through the net, or maybe the wording is slightly ambiguous and the problem has not been explained as well as it could. However, when so many people have hit the target and one marksman misses ten times on the run, he/she can hardly shoot his/her own foot and conclude that because the gun is working properly the fault must lie in the target.
Or to put it more clear:
if about 4400 people have solved this problem, do you think they all solved it wrong?
Don't you think we would have been told the answer was wrong much and much earlier?
Re: Problem 120
Posted: Mon Aug 08, 2011 9:58 am
by oleglyamin
Thanks for replying. I pm-ed you.
Re: Problem 120
Posted: Mon Aug 08, 2011 10:54 am
by oleglyamin
Error's been found. It was my math.
Problem 120
Posted: Fri Jan 20, 2017 5:31 pm
by mdenhoed
Issue already solved.
Re: Problem 120
Posted: Fri Jan 20, 2017 6:33 pm
by mpiotte
@mdenhoed Please don't create a new thread for a problem if one already exists.
Re: Problem 120
Posted: Fri Sep 07, 2018 4:06 am
by cornielleandres
bobfin wrote: Thu Oct 22, 2009 10:06 pm
Apoplogies for posting on a relatively old problem but I've only recently discovered the site. Could anyone provide some feedback on problem 120. I thought I had a suitable algorithm which correctly calculates the a = 7, rmax = 42 example provided. However my total is incorrect. Hoping this doesn't breach your guidelines re-solutions, could anyone confirm that these early values are correct:
a = 3 rmax = 6
a = 4 rmax = 8
a = 5 rmax = 10
a = 6 rmax = 12
a = 7 rmax = 42
a = 8 rmax = 48
a = 9 rmax = 54
a = 10 rmax = 60
a = 11 rmax = 110
a = 12 rmax = 120
a = 13 rmax = 130
a = 14 rmax = 140
a = 15 rmax = 210
jaap wrote: Sat Sep 25, 2010 2:42 am
frogboy77 wrote:a=5; rmax=20 when n=7
Correct.
frogboy77 wrote:p.s can this problem be done in ULL range?
sorry mean 64bit int range
It can quite comfortably be done in 32 bit range too.
How can a=5; rmax=10 and a=5;rmax=20 both be correct?
Re: Problem 120
Posted: Fri Sep 07, 2018 6:54 am
by kenbrooker
Only one is correct...
Re: Problem 120
Posted: Tue May 26, 2020 12:13 am
by papadil
I started with the problems just recently and use it to learn different programming languages. But I'm posting a question on this problem that is bugging me. For example, one of the above entries has, for a=9, max = 60. That is true for n = 3, but for n=9 it is 80. What am I missing, in particular since n is not bounded (yes the entries will repeat eventually due to the modulus)? Clarification would be much appreciated.
Re: Problem 120
Posted: Tue May 26, 2020 5:58 am
by kenbrooker
rmax does not equal 60 when n=3...