Share your repls and programming experiences

← Back to all posts
Choice Randomizer
thejoeman24 (31)

But in your choices and it randomizes the choices

malvoliothegood (746)

Nice use of the delay to give the impression of the program "thinking".

TrevorHurst2 (10)

An easier way to do this might be

import random
choices = []
numOfChoices = int(input('Number of choices: '))
for i in range(numOfChoices):
    choiceString = ''.join(["Choice number ",str(i+1),': '])
    choice = input(choiceString)
print("I chose",random.choice(choices))