Introduction to NumPy (easy)

Introduction to NumPy (easy)

University

10 Qs

quiz-placeholder

Similar activities

Quiz 10 Susulan  Teori Bahasa dan Otomata 2022-1

Quiz 10 Susulan Teori Bahasa dan Otomata 2022-1

University

10 Qs

TIN HỌC ( ÔN THI ĐẦU RA 31 - 40)

TIN HỌC ( ÔN THI ĐẦU RA 31 - 40)

University

10 Qs

ロジックテスト (Đề kiểm tra năng lực IT)

ロジックテスト (Đề kiểm tra năng lực IT)

University

12 Qs

SQLite - Writing Queries

SQLite - Writing Queries

University

9 Qs

CHUONG 4: KT CÁC NVTT

CHUONG 4: KT CÁC NVTT

University

10 Qs

UAS Sistem Operasi Open Source

UAS Sistem Operasi Open Source

University

10 Qs

Post Test #4 - Python Fundamental #3

Post Test #4 - Python Fundamental #3

University

10 Qs

C Wrapup Quiz Deutsch

C Wrapup Quiz Deutsch

University

12 Qs

Introduction to NumPy (easy)

Introduction to NumPy (easy)

Assessment

Quiz

Computers

University

Practice Problem

Easy

Created by

Prynze Reyes

Used 12+ times

FREE Resource

AI

Enhance your content in a minute

Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

line 1: import numpy as np

line 2: array = ______ ([1,2,3,4,5])

array

FILL IN THE BLANK

np.Array

np.array
numpy.array
np.arrayy

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Line 1: array = np.array([1,2,3,4,5])

Line 2: print(array[2])

What will the code print?

3
6
4
2

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

import numpy as np

array = np.array([1,2,3,4,5])

array[1] = 7

print(array)

What does line 3 do?

Prints the 'array' without any changes.
Updates the value at index 1 in the 'array' to 7.
Adds a new element with the value 7 at index 1 in the 'array'.
Deletes the element at index 1 in the 'array'.

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

import numpy as np

array = np.array([1,2,3,4,5])

array[1] = 7

print(array)

What will the code print?

[1,7,7,4,5]
[1,7,3,7,5]
[1,2,3,4,5]
[1,7,3,4,5]

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

import numpy as np

array = np.array([1,2,3,4,5])

array += 10

print(array)

What does this code print?

[21, 22, 23, 24, 25]
[6, 7, 8, 9, 10]
[11, 12, 13, 14, 15]
[10, 10, 10, 10, 10]

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

import numpy as np

array = np.array([1,2,3,4,5])

sum_all = np.sum(array)

print(sum_all)

What is the result of this code?

10
15
20
25

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

import numpy as np

array = np.array([1,2,3,4,5])

sum_all = ______(array)

print(sum_all)

Fill in the blank

np.Sum

np.addition

np.sum
np.add

Create a free account and access millions of resources

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

By signing up, you agree to our Terms of Service & Privacy Policy

Already have an account?