文件名称:src
- 所属分类:
- JSP源码/Java
- 资源属性:
- [MacOS] [Java] [源码]
- 上传时间:
- 2012-11-26
- 文件大小:
- 3kb
- 下载次数:
- 0次
- 提 供 者:
- 王*
- 相关连接:
- 无
- 下载说明:
- 别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容均来自于网络,请自行研究使用
摇色子程序。首先可以选择色子的面数(比如6或者10)。设定初始值后,摇动色子,得到新的点数。-1. a constructor that allows users of the class to specify the number of sides on each dice separately. In other words, the constructor has two input parameters.
2. methods that allow a user to set and get the face values of each dice object separately. For
instance, I could set the first dice s face value to 2 and the second dice s face value to 9
(assuming the second one is a 10-sided Dice).
3. a single method that rolls both dice
4. a method that returns the current sum of the face values on the dice
5. a toString method that returns an informative descr iption, such as "first dice: value,
second dice: value" where value would be the current face value of that dice.
2. methods that allow a user to set and get the face values of each dice object separately. For
instance, I could set the first dice s face value to 2 and the second dice s face value to 9
(assuming the second one is a 10-sided Dice).
3. a single method that rolls both dice
4. a method that returns the current sum of the face values on the dice
5. a toString method that returns an informative descr iption, such as "first dice: value,
second dice: value" where value would be the current face value of that dice.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
src
...\.DS_Store
__MACOSX
........\src
........\...\._.DS_Store
src\Dice.java
...\DiceRoller.java
...\PairOfDice.java
...\.DS_Store
__MACOSX
........\src
........\...\._.DS_Store
src\Dice.java
...\DiceRoller.java
...\PairOfDice.java