CS 1073 Introductory Programming
for Scientific Applications
Game of Craps


Rules for the game: In the game of Craps, players roll a pair of dice. Only the sum of the spots matters: a number between 2 and 12. The shooter does the rolling. Below, win or loss refers to the shooter. Other betters can bet with or against the shooter.

The above is the simplest form of street craps. For the rules of the more complicated casino craps see: Casino craps.


A Java program to simulate craps: Here is a simple Java program that just mimics the rules above:

Here are results of a sequence of runs: