Problem 232

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.
User avatar
sfabriz
Posts: 175
Joined: Thu Apr 06, 2006 12:18 am
Location: London - UK

Re: Problem 232

Post by sfabriz »

After having read Daniel's stunning explanation for 233 I was wondering if anyone of you mathematicians would like to do the same thing for this one. It's been really hard to solve for me and still I can't understand many of the methods used by those who posted on the problem's thread. :shock:
So, if anyone would like to do it, I'll be a very interested reader. Probability theory is really one of my worst weaknesses...
Cheers,
sfabriz
Image
User avatar
hk
Administrator
Posts: 12831
Joined: Sun Mar 26, 2006 10:34 am
Location: Haren, Netherlands

Re: Problem 232

Post by hk »

But please do it not here in this forum....
Image
War ruins the life and health of untold numbers of innocent children.
User avatar
sfabriz
Posts: 175
Joined: Thu Apr 06, 2006 12:18 am
Location: London - UK

Re: Problem 232

Post by sfabriz »

Of course, I meant in the problem's thread...
Image
User avatar
hk
Administrator
Posts: 12831
Joined: Sun Mar 26, 2006 10:34 am
Location: Haren, Netherlands

Re: Problem 232

Post by hk »

I was afraid that some helpful guy would start something here we would've had to delete immediately.
Image
War ruins the life and health of untold numbers of innocent children.
User avatar
sfabriz
Posts: 175
Joined: Thu Apr 06, 2006 12:18 am
Location: London - UK

Re: Problem 232

Post by sfabriz »

Oh yes, of course. I didn't specify that 'cause i gave for granted that we can't write anything here that could spoil the problem for others.
Cheers,
Sfabriz
Image
zwuupeape
Posts: 189
Joined: Tue Jun 09, 2009 6:11 pm

Re: Problem 232

Post by zwuupeape »

Just to find out if my solution is at least approximately true.

If the target is 66 points, Player 2 wins with probability 0.811849718826
If the target is 50 points, Player 2 wins with probability 0.78973645941617376
If the target is 10 points, Player 2 wins with probability 0.6999731081357714
User avatar
daniel.is.fischer
Posts: 2400
Joined: Sun Sep 02, 2007 11:15 pm
Location: Bremen, Germany

Re: Problem 232

Post by daniel.is.fischer »

Close, but not correct :(
Il faut respecter la montagne -- c'est pourquoi les gypaètes sont là.
sivakd
Posts: 217
Joined: Fri Jul 17, 2009 9:37 am
Location: California, USA
Contact:

Re: Problem 232

Post by sivakd »

Is
Expand
0.66057914
correct for 10?

Edit: Never mind, I solved this problem.
Image
puzzle is a euphemism for lack of clarity
DDgeva
Posts: 15
Joined: Mon Dec 29, 2008 12:47 pm

Re: Problem 232

Post by DDgeva »

I still don't get this problem. My algorithm is pretty straight-forward and very fast, but the answer isn't correct.
This happens to me way too often..

Am I missing something here?
Am I correct stating the the probability of player 2 winning when they're playing upto 1 is 1/3?

My program's outputs:
Playing up to 2: 0.52
up to 4: 0.601777777777777777777777777778
up to 10: 0.667026820050150500796231363509
up to 30: 0.761458127957947605300352303773
up to 80: 0.823494959687249598060259595678
User avatar
jaap
Posts: 588
Joined: Tue Mar 25, 2008 3:57 pm
Contact:

Re: Problem 232

Post by jaap »

DDgeva wrote:Am I correct stating the the probability of player 2 winning when they're playing upto 1 is 1/3?
Yes, but your other answers are incorrect.
When playing up to 2 the answer should be 0.5259259259259259...
For 4 it is 0.603753086419753...
DDgeva
Posts: 15
Joined: Mon Dec 29, 2008 12:47 pm

Re: Problem 232

Post by DDgeva »

jaap wrote:
DDgeva wrote:Am I correct stating the the probability of player 2 winning when they're playing upto 1 is 1/3?
Yes, but your other answers are incorrect.
When playing up to 2 the answer should be 0.5259259259259259...
For 4 it is 0.603753086419753...
I'm getting 0.52 even when calculating it by hand, using the same approach that produced a correct result for a game up to 1.
I'm guessing my method is probably incorrect. I'll try to figure out what I'm missing..
Waldovski
Posts: 32
Joined: Thu Jul 08, 2010 11:11 am

Re: Problem 232

Post by Waldovski »

Question: When you say "On each turn Player 2 selects the number, T, of coin tosses that maximises the probability of her winning.", do you mean maximising the probability of reaching 100 in one turn? (in other words, am I right in saying that the value of T will depend on Player Two's current score only?)
harryh
Posts: 2091
Joined: Tue Aug 22, 2006 9:33 pm
Location: Thessaloniki, Greece

Re: Problem 232

Post by harryh »

Waldovski wrote:Question: When you say "On each turn Player 2 selects the number, T, of coin tosses that maximises the probability of her winning.", do you mean maximising the probability of reaching 100 in one turn?
Your question has already been answered; see this previous post.
Hippunky
Posts: 6
Joined: Sat Feb 26, 2011 10:36 pm

Re: Problem 232

Post by Hippunky »

Hi All,

I've tried calculating T (the number of throws player 2 chooses) using a very simple formula based on "P2 score" - "P1 score". Should I instead be looking to a more dynamic means of calculating T on each turn (based on more that just the difference in scores) as I can't convince my current approach to return a probability >= 0.6 for the 'first to four points' variant.

Thanks,

Will.
ffff0
Posts: 50
Joined: Sun Aug 21, 2011 6:26 am
Location: Moscow, Russian Federation

Re: Problem 232

Post by ffff0 »

I'm stuck here.

Can someone check my values please:
10 - 0.6700226472266161789570328463236506093
20 - 0.7289790525667717256992685609669337712
50 - 0.7943581957799124887668550310834422535

And i'd like to PM my value for 100 to someone.

Edit:
Finally solved this one! I thought that I calculate T values for all possible parameters, but I totally forget about another one.

Correct values will be:
10 - 0.670064571682367
20 - 0.729009756737729
50 - 0.794385833126634
Image
MuthuVeerappanR
Posts: 539
Joined: Sun Mar 22, 2015 2:30 pm
Location: India
Contact:

Re: Problem 232

Post by MuthuVeerappanR »

I solved this problem yesterday and was playing around with the values... I'm noticing a slightly counter-intuitive result which may be wrong or may be hard to believe...

I tried to find the probability when both the players are presented with the option of choosing the number of tosses before their turn. I thought, now that the game is symmetric except for the first mover advantage (or disadvantage), the B's winning probability should be somewhere around 1/3 because in the classic case of one toss allowed for both players, the first player wins with probability 2/3.

But when I modified my program, it says no matter what the final limit is, when A starts the game, B will win with probability 1. And when the limit is high, no matter who starts B will win with probability 1. Am I missing something? or is there a reason for this?


PS: Though the probability of my program being wrong is very low :D , it still is possible. If thats the case, can someone determine the value of B's winning probability when A starts the game and both players have the option of choosing T before their turn?
Image
It is not knowledge, but the act of learning, not possession but the act of getting there, which grants the greatest enjoyment.
papadil
Posts: 10
Joined: Tue May 26, 2020 12:08 am

Re: Problem 232

Post by papadil »

I know I'm a little late to this problem. Just noting that the phrase "will always selects the number" does not seem correct. Should be one of: "will always select the number" (no 's' in select) or, "always selects the number" (no 'will'). I know...nitpicking....
User avatar
RobertStanforth
Administrator
Posts: 2666
Joined: Mon Dec 30, 2013 11:25 pm

Re: Problem 232

Post by RobertStanforth »

papadil wrote: Fri Apr 19, 2024 1:36 am I know I'm a little late to this problem. Just noting that the phrase "will always selects the number" does not seem correct. Should be one of: "will always select the number" (no 's' in select) or, "always selects the number" (no 'will'). I know...nitpicking....
Thank you for taking the time to flag this! I have corrected it to "will always select the number".
Post Reply