Advertisement
Guest User

Untitled

a guest
Feb 27th, 2020
134
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.69 KB | None | 0 0
  1. /**
  2. * Here is the computer opponent's algorithm: 20 is chosen as the computer's
  3. * border value for determining the end of a turn, since the average gain
  4. * equals the average loss --> 1/6 of the time all points are
  5. * lost, and the remaining 5/6 of the time there is an average gain of
  6. * (2+3+4+5+6)/5 = 4 points. Since 5/6 * 4 = 20/6 there will be an equilibrium
  7. * between potential loss and gain when 1/6 * x = 20/6 --> x = 20. The computer
  8. * plays it safe, so it decides to secure it's points if they're exactly 20.
  9. */
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement