in reply to Re^8: Marilyn Vos Savant's Monty Hall problem
in thread Marilyn Vos Savant's Monty Hall problem
Perhaps the best way is to be verbose as in:
my @available; if ( $door[ $choice ] eq 'car' ) { # Can't beat him yet @available = grep { $choice != $_ } 0 .. 2; } else { # Make him lose! @available = grep { $doors[ $_ ] eq 'car' } 0 .. 2; }
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^10: Marilyn Vos Savant's Monty Hall problem
by BrowserUk (Patriarch) on Aug 23, 2004 at 23:28 UTC |