You are on page 1of 1

You have to submit the ipynb file for the assignment. Submit that by 15th May, 2023.

Please
include your Full name and Enrollment number in the file. Use Google Colab to create your ipynb
file.

Numpy:

1. Create an array with 15 elements equally spaced. The min & max value
of the array should be 2 and 25 respectively.
2. Create an array with 34 random values and slice top 10 values from that
array.
3. Create a 3x5 array with random integers. Slice array such that 3rd rows,
elements from 1st to 4th are picked.
4. Create a 3x5 array with random integers. Slice array such that from all
rows, elements from 2nd to 4th are picked.
5. Create a 3x4 array where values are randomly picked from following
values. [2, 5, 7, 4, 9, 0]
6. Create a 5x4 integer array print its dimensions.
7. Create a 2x3 array with all 1’s in float data type.
8. Create a 3x4 integer array from a range between 100 to 200 such that
the difference between each element is 5.
9. Create a 5x3 array and find max value in row 3rd and min value in
column 2nd.
10. Create a 10x7 integer array with values between 4 and 37. Further
filter that array for all elements greater than 25.
11. Create a 5x5 array with values randomly picked from the following
elements. [1, 4, 5, ‘a’, ‘b’ , np.NaN]. Further filter all non-numeric values
from this array.
12. Create an array with 30 values that are in normal distribution. Values
should be in the range of 0 to 1.
13. Create a 5x5 array with 50 values that are in uniform distribution.
Value should be in the range of 10 to 150.
14. Create two arrays of 10 elements and add their values with ufunc.
15. Create a custom universal function to do element-wise multiplication
for two arrays.

You might also like