###Concepts:
* Build-in module.
* Practice on module, class, object, tuple.
###Codes:
import random
class Dice:
def roll(self):
first = random.randint(1, 6)
second = random.randint(1, 6)
third = random.randint(1, 6)
forth = random.randint(1, 6)
fifth = random.randint(1, 6)
return first, second, third, forth, fifth
dice = Dice()
print(dice.roll())
浙公网安备 33010602011771号