![]() ![]() If you want more numbers in the array, then np.random.randint(5,20,6) This means a random number will be generated within the range – of 5 to 19 (20 exclusives). Rand() will give a floating-point number if you want integer values, then use randint() np.random.randint(5,20) If you want the numbers inside the array from Standard Normal or Gaussian Distribution. This means the array will start printing from 0 and ends at 10 with a step/increment of 2. ![]() You can also use arange() method by inserting an increment or step as a third argument. This means the array will start printing from 0 and ends at 10-1 i.e., 9 But if you change or create a new notebook that is a new session, then you need to import numpy again.Ģ.
0 Comments
Leave a Reply. |