test01

test01

Professional Development

10 Qs

quiz-placeholder

Similar activities

SENZ AIOT SAVANTS - JV & JS

SENZ AIOT SAVANTS - JV & JS

Professional Development

10 Qs

Quizz_Python_2

Quizz_Python_2

Professional Development

10 Qs

HERData

HERData

Professional Development

10 Qs

Day 1 - Basics of Java

Day 1 - Basics of Java

Professional Development

14 Qs

M365 Security Pillar 1 (Identity & Access Management)

M365 Security Pillar 1 (Identity & Access Management)

Professional Development

10 Qs

aXQtMjktMTEtMjAyMg==

aXQtMjktMTEtMjAyMg==

Professional Development

10 Qs

Family Quizz

Family Quizz

5th Grade - Professional Development

15 Qs

Java Collections

Java Collections

Professional Development

10 Qs

test01

test01

Assessment

Quiz

Computers

Professional Development

Practice Problem

Medium

1, 2, 3

+7

Standards-aligned

Created by

hubert Lu

Used 7+ 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

What is the output of the following code?

import numpy as np

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

y = np.array([[5, 6], [7, 8]])

z = np.dot(x, y)

print(z)

a) [[19, 22], [43, 50]]

b) [[5, 6], [7, 8], [1, 2], [3, 4]]

c) [[6, 8], [10, 12]]

d) [[1, 2], [3, 4], [5, 6], [7, 8]]

Tags

1

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the output of the following code?

import numpy as np

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

y = np.array([5, 6])

z = x * y

print(z)

a) [[5, 12], [15, 24]]

b) [[5, 6], [5, 6]]

c) [[1, 2, 5, 6], [3, 4, 5, 6]]

d) ValueError: operands could not be broadcast together with shapes (2,2) (2,)

Tags

2

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What is the output of the following code?

x = 5

if x > 3:

print("x is greater than 3")

else:

print("x is less than or equal to 3")

a) x is greater than 3

b) x is less than or equal to 3

c) x is equal to 3

d) None of the above

Tags

3

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the data type of the value 5 in Python?

float

string

Integer

list

Tags

4

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is a valid string declaration in Python?

string("Hello")

str = Hello

str('Hello')

string = 'Hello'

Tags

5

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you get the length of a string s in Python?

len(s)

s.len()

length(s)

s.length()

Tags

6

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which function is used to convert a string to an integer in Python?

int()

str()

convert()

toInt()

Tags

7

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?