how to create a loop that will make sure that my dice can be rolled as many times as required?
here's my code as a start off.
import random
dice=random.randrange(1,5)
dice2=random.randrange(1,7)
dice3=random.randrange(1,13)
sim=input (“Which sided dice would you like to roll? You can choose a 4-sided dice, a 6-sided dice or a 12-sided dice.”)
if output=4
then print (“The 4-sided dice has rolled to”,dice)
elif output=6
then print (“The 6-sided dice has rolled to”,dice2)
elif output=12
then print (“The 12-sided dice has rolled to”,dice3)
else input (“Please input a number 4, 6 or 12”)
there are errors within my coding, but i am more concerned about creating the loop, thanks (:
please don't be harsh, im new to python