added dice example ex4: