Description Usage Arguments Details Value Examples
View source: R/monty-hall-problem (4).R
determine_winner( final.pick, game )
generates the outcome of winning
granted the contestant selects the door containing a car in his/her final
pick. It also generates the outcome of losing if the contestant selects the
door containing a goat in his/her final pick.
1 | determine_winner(final.pick, game)
|
... |
Based on the game playing strategy if the final.pick equals " the return is a "WIN" if the final.pick equals "goat" the return is "LOSE" assigned. |
Selecting the final pick as either the door that has a car behind it, or a door that has a goat behind yields the results of winning or losing at the end of the game.
The function returns "WIN" if final.pick is equal to "car", the functions returns "LOSE" if final.pick is equal to "goat".
1 | determine_winner( final.pick, game )
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.