// Dice.java
/**
* Implements a Dice object (a die)
*
* @author andrianoff
* @version 7/23/07
*/
public class Dice
{
/**
* Constructs a die
*/
public Dice()
{
}
/**
* Rolls a die - generates a random number in 1 .. 6
* @return the face value of the die
*/
public int roll()
{
return (int) (Math.random()*6) + 1;
}
}