Project Java Webmaster: Glenn A. Richard
Mineral Physics Institute
SUNY Stony Brook
This game is an implementation of the Prisoners' Dilemma, a classic problem in which competition between players is structured in such a manner that when decisions are made based on individual self-interest, the result is likely to be less than optimal for each player.
In this game, we assume that two players are accused of stealing a diamond and are placed in separate jail cells with no chance of communicating with each other. The jailer offers each prisoner the same deal, which is as follows:
Do you see the dilemma?
In order to use this applet, you need three to five players. Any number of them can be virtual players who will be implemented by the computer. Two players will compete during each round.
Use the radio buttons to select the number of players. Where it is indicated that you should select the rules of the game, you need to choose a point structure that governs how long the jail sentences are for each choice combination. Then click the Start Game button. Subsequently, you will be asked for how many rounds you would like to play. Click in the field to the right of the prompt, type in a number, and hit enter. You then need to enter names for the players. For each real player, you should enter a name. If you hit enter without entering a name first, that player will be virtual, and will be implemented by the computer. Each virtual player will proceed according to a particular strategy.
After the names have been entered, play can begin. A prompt tells you whose turn it is. With the other players not watching, the player whose turn has arrived should select either the Admit or Deny button. The player then must select the OK button to finalize the choice. After the choice has been finalized, the other players can look at the screen, but until both players for that round have made their moves, there will be no sign of what choice was made. Recall that each player is to make a choice in secret. Once both players for a given round have entered their choices, the results become posted and the next round begins. The status line will announce when the game is over.
Mikhail Sabaev: sabaevm@ug.cs.sunysb.edu
Konstantin Lukin: klukin77@yahoo.com