from random import randrange
class Dice:
  def __init__(self):
    self.num=1
  def roll(self):
    self.num=randrange(1,7)
  def set(self,x):
    self.num=x
  def getValue(self):
    return self.num
class ColorDice(Dice):
  def __init__(self):
    Dice.__init__(self)
    self.color="yellow"
  def getColor(self):
    return self.color
  def setColor(self,dath):
    self.color=dath
    
d1=Dice()
print (d1.getValue())
d1.roll()
print (d1.getValue())
d1.set(5)
print (d1.getValue())

d2=ColorDice()
print (d2.getValue())
d2.roll()
print (d2.getValue())
print (d2.getColor())
d2.setColor("red")
print (d2.getColor())
