>> The previous choice will have no consequence on the outcome of this new choice.
The previous choice does have a consequence on what door the host opens. That is how the outcome is affected by the original choice, and that is the piece that I believe you are missing in your analysis.
Unlike the gambler's situation that started this thread, in this case the previous events do have an effect on later events. If you pick a door with a donkey, that forces the host to open the other door with a donkey. Therefore, your choice affects what the final options will be, and it is that effect that shows up in the different probability.
Yes Daved. But the host always opens a losing door, no matter my choice. So his action has a null value.
I'm still firmly convinced of my answer, but can't ignore the overwhelming majority. So, I'll give this some hard thought before I post again.
I just think you guys are trying to mix events and forgetting that the one event that matters is that last instant where the contestant is faced with two doors.
Meanwhile, sorry robwhit. Didn't read your post correctly the first time.
Originally Posted by brewbuck:
Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.
*sigh*
Read the question: "If you're the contestant, should you switch doors? Should you stay on your door? Does it matter?"
The question is not "which of the doors has the highest probability of winning?" The question is: "which of the two strategies is better, or are they equally viable?"
Look up a C++ Reference and learn How To Ask Questions The Smart WayOriginally Posted by Bjarne Stroustrup (2000-10-14)
1x + 2y - 1y = 1x + 1y no matter how you look at it.
Thats not how it works. You have to remember the host removes a door with a donkey. Theres only a 1/3 chance that he has 2 donkeys. I dident get it at first either. Good luck figuring it out1x + 2y - 1y = 1x + 1y no matter how you look at it.
Oops, sorry.I answered that question on my very first post.
Basically, you are saying: the probability of hitting the right door is 1/2 if the contestant does not switch.It really doesn't matter. MY chance of hitting the right door is 1:2 whether I switch or not.
Do you agree then, that if there are three billion contestants, all of whom choose at random and do not switch, about 1.5 billion contestants will choose the right door?
Do you also agree that if all of them choose at random, about 1 billion of them will choose the right door at the start, and about 2 billion of them will choose the wrong door at the start?
Look up a C++ Reference and learn How To Ask Questions The Smart WayOriginally Posted by Bjarne Stroustrup (2000-10-14)
Correct.
Correct.Do you agree then, that if there are three billion contestants, all of whom choose at random and do not switch, about 1.5 billion contestants will choose the right door?
Correct.Do you also agree that if all of them choose at random, about 1 billion of them will choose the right door at the start, and about 2 billion of them will choose the wrong door at the start?
You are now going to ask me if I don't see the "obvious" inconsistency.
But there isn't any inconsistency. It just so happens that your first and second question pertains to the last part of the game when there are only 2 doors left. And and the 3rd question to the first part of the game when there were 3 doors.
Originally Posted by brewbuck:
Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.
Ah, but the contestants have to go through the first part first. They have to select a door, and we know they will not switch. If they do not switch, how can it be that it appears that half a billion of them have switched?But there isn't any inconsistency. It just so happens that your first and second question pertains to the last part of the game when there are only 2 doors left. And and the 3rd question to the first part of the game when there were 3 doors.
Look up a C++ Reference and learn How To Ask Questions The Smart WayOriginally Posted by Bjarne Stroustrup (2000-10-14)
laserlight, which side are you on? It's a little hard to tell.
Originally Posted by brewbuck:
Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.
Hint: Redirect stdin at the command line or pipe it with another program. Also increase from 10 tries to something more substantial. Etc. etc..Code:#include <stdio.h> #include <stdlib.h> #include <time.h> int selectBadDoor(int iRightDoor, int iGuess); int doRound(void); int selectBadDoor(int iRightDoor, int iGuess) { int i; for(i=0;i<3;i++) { if((iRightDoor != i) && (iGuess != i)) { return i; } } return -1; } int doRound(void) { int iGuess, iRightDoor, iBadDoor; char yn; /* Select right door. */ iRightDoor = rand() % 3; /* [0,3) */ printf("\tDEBUG: %d has been selected.\n", iRightDoor+1); /* Ask user for original selection. */ printf("Select a door [1-3]: "); fflush(stdout); scanf("%d", &iGuess); iGuess--; /* Select a bad door. */ iBadDoor = selectBadDoor(iRightDoor, iGuess); /* Ask user to switch. */ printf("Door %d has been eliminated. Do you wish to switch? [Y/N]: ", iBadDoor+1); fflush(stdout); getchar(); scanf("%c", &yn); /* Confuse code reader for fun. */ yn = ((iGuess==iRightDoor) && !((yn == 'Y') || (yn == 'y'))) || (!(iGuess==iRightDoor) && ((yn == 'Y') || (yn == 'y'))); printf("You %s!\n", yn?"win":"lose"); return yn; } int main(void) { int iGoodSwitch = 0, iBadSwitch = 0, i, iResult; srand(time(NULL)); for(i=0;i<10;i++) { iResult = doRound(); if(iResult) { puts("Switch = Good."); iGoodSwitch++; } else { puts("Switch = Bad."); iBadSwitch++; } putchar('\n'); } printf("Switching was the right move %d times.\n", iGoodSwitch); printf("Staying was the right move %d times.\n", iBadSwitch); return 0; }
Note: I know rand() isn't truly random, but this is just for fun.
Also of note: I left in a statement to print the value of the selected door which ruins the guessing aspect, but makes it easy to debug in case there are suspected errors.
I think that switching is the better strategy. That is, those who switch can be expected to win 2/3s of the time.laserlight, which side are you on? It's a little hard to tell.
That's ignoring the contradiction.Because the odds became 50% when the host eliminated a bad door! They are no longer 33%. By eliminating a wrong door the host increased the contestant odds to 50%.
By the way, would you accept a computer simulation as evidence?
EDIT:
Heh, MacGyver already wrote one, apparently.
Look up a C++ Reference and learn How To Ask Questions The Smart WayOriginally Posted by Bjarne Stroustrup (2000-10-14)