#here is the code #you can copy it (even this part) #credits to Wildfire_the_dragon on scratch import random round = 0 while True: dice = [] round += 1 for i in range(5): dice.append(random.randint(1, 6)) print(dice[0], dice[1], dice[2], dice[3], dice[4]) if all(x == dice[0] for x in dice): print("Yahtzee!!! you did " + str(round) + " rolls") break