mercredi 30 août 2017

Adding the randomly picked numbers

Sorry for the English in advance. The following code gives me the random picks and I want the sum of them'

import random
print ('Your five random numbers are')
for i in range(1):
print (random.sample([10,12,14,15,17,24,27,30,32,35,38,39,42,45,46,47],5))

OUTPUT

Your five random numbers are [39, 10, 15, 38, 24]




Aucun commentaire:

Enregistrer un commentaire