Search Header Logo

PP_Week12_Batch1_Numpy

Authored by Narasimha Reddy Soora

Professional Development, Computers

Used 1+ times

PP_Week12_Batch1_Numpy
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

16 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is a correct syntax to create a NumPy array?

Media Image
Media Image
Media Image

2.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Media Image

What is a correct syntax to print the numbers [3, 4, 5] from the array arr given in the image

print(arr[2:5])

print(arr[2:6])

print(arr[2:4])

print(arr[3:6])

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is a correct syntax to return the shape of an array?

shape(arr)

arr.shape

arr.shape()

4.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Media Image

What is the correct syntax to reshape the array given in the image into 4 arrays with 3 elements?

newarr = arr.reshape(3, 4)

newarr = arr.shape(3, 4)

newarr = arr.reshape(4, 3)

newarr = arr.shape(4, 3)

5.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Media Image

What is the output of the code given in the image?

[1 3 6]

[6]

[3 6 9]

[9]

6.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

What is a correct syntax to subtract the numbers from arr1 with the numbers from arr2?

Media Image
Media Image
Media Image
Media Image

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the correct method for getting the Natural Logarithm (Logarithm at base e)?


arr = np.arange(1, 10)

np.log(arr)

np.loge(arr)

np.natural(arr)

np.ln(arr)

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?

Discover more resources for Professional Development