import numpy data = [15, 30, 45]N = 20new_data = numpy.random.choice(data, N)print(new_data)
Standard input is empty
[15 45 45 30 30 15 45 15 15 45 30 15 15 30 30 45 30 15 30 30]
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!