Deadline for entries: Monday, July 10, 2000.
Intro | Rules | Enter | FAQ | Links |
last updated: June 25, 2000.
Summary: Write a program to play Rock-Paper-Scissors, and enter it to play in an open competition against other programs.
Purpose: To have fun, and maybe learn something.
RoShamBo (also known as Rock-Paper-Scissors) is a simple game, but the best strategy can be quite complicated when playing against fallible opponents.
The game is played between two players. On each turn, the players simultaneously choose one of "rock", "paper", or "scissors". If they choose the same item, the result is a tie; otherwise rock crushes scissors, paper covers rock, or scissors cuts paper. A match consists of a series of turns between the two players.
The game is trivial from a game-theoretic point of view. The optimal mixed strategy is to choose an action uniformly at random (one-third probability of each). This will ensure a break-even result in the long run, regardless of how strong (or how weak!) the opponent is.
However, against predictable opponents, a player can attempt to detect patterns in the opponent's play, and exploit those tendencies with an appropriate counter-strategy.
The RoShamBo Programming Competition is a tournament between computer programs that play Rock-Paper-Scissors. Some of the programs in the tournament will use sub-optimal strategies, and will be vulnerable to a perceptive and adaptive opponent. Of course, there is always a risk associated with such a prediction, as the opponent may be attempting to trap you, by anticipating your reaction to previous plays.
The most successful programs will recognize a variety of patterns and relationships, and use that information to gain an advantage over each opponent, without being susceptible to similar attacks.
To enter the competition, participants will write a C procedure to play Rock-Paper-Scissors, given only the complete history of the match against the current opponent. The test suite is an example program for conducting RoShamBo tournaments (this may not be the exact version used in the official competition, but the protocol for computer players will be the same). The test suite contains many examples of RoShamBo players, including almost all of the top contenders from the first programming competition. A smaller sample program is also available (this includes only the dummy bots).
Please note that the computer players used in the sample programs will not be playing in the official competition (except Random (Optimal)). The exploitable characteristics of the intentionally weak programs in the actual tournament will be quite subtle, and may change over time.
1. All programs must be written in standard C, using common libraries. All code must compile cleanly using:
There must be no reported errors and no warnings of any kind. Note that
2. Each player will be a C function with no parameters, returning a single integer value:
0 = rock, 1 = paper, or 2 = scissors
3. Computer players must be fast! Each player must be able to finish a 1000 turn match in one second on the tournament machine. This should allow several passes through a full history array, but may preclude certain compute-intensive algorithms. Slower programs will be rejected. (Hint: using static variables may avoid some unnecessary re-computation). Please use distinct names in the code, such as prefacing all variables and procedures with your initials.
Limitations on memory usage may be added later, if necessary (but using less than 50K should not pose a problem).
There is no limit on program length, but there will be a special side competition for smaller programs (roughly 40 C statements or less). Qualification for this category is at the discretion of the organizer, and will be based on number of lines, keywords, size of the object file, and other measures.
4. The length of each match will be 1000 turns. The numerical result of each match will be used in the overall standings. For example, 200 wins, 300 losses, and 500 ties over 1000 turns would net -100 points for that match. The match result (win, lose, or draw) is also important. A draw is defined to be a range of outcomes statistically close to the break-even result (0 points).
5. Players may access full history arrays for the match, as global
variables. These arrays will be called
6. There is no rule 6.
7. All submissions become public domain. However, appropriate credit will be given to the original author(s) for any ideas or source code that are used or published in the future.
8. The decisions of the organizer are final, and supercede all other rules. No further discussion will be entertained.
1. Give your program a name to appear on the tournament crosstable (maximum of 18 characters). The names of all programs in the first competition are reserved for their original author.
2. Acknowledge any other programs you may have used as a model. Any entry deemed to be too similar to an existing program will be rejected without further consideration.
3. Submit your program by e-mail to email@example.com . Please put "RoShamBo" in the subject. The e-mail must include the source code in the body of the message, in PLAIN TEXT only: no HTML, no attachments. If you believe you also qualify for the mini-program competition, please indicate that in your message.
|FAQ (Frequently Asked Questions)|
The First International RoShamBo Programming Competition
(Sept 1999) Announcement and Rules Results (Part 1) (Part 2)
the sample program is a smaller version (only "dummy bots" from the previous competition).
Check out the World RPS Society, home of
an article and a tournament report on the first competition were published in:
The International Computer Games Association (ICGA) Journal (Vol. 23, No. 1, March 2000)
an article also appeared in The Mind Sport Olympiad's "Mindzine"
Glicko rating system used for chess. (Click on Michael's link for all the gory details).
here are some recent results, with strong new programs by Don Beal and Neil Burch.
Intro | Rules | Enter | FAQ | Links |
U of A GAMES group
You are visitor to this page since June, 2000.