OverIQ.com
Run (or Hit F9)
import random marks = [122, 45, 23, 78, 65, 12] for i in range(len(marks)): marks[i] = random.randint(1, 100) # assign some random value between 1 to 100 to all elements print(marks)