Search Header Logo

Python Quiz

Authored by Krishna Kakkar

Computers

8th Grade

Python  Quiz
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

20 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will be the output of the following code? print(type([]) is list)

True

False

TypeError

None

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the correct way to import the NumPy library?

import numpy

import numpy as np

from numpy import *

All of the above

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following data structures is mutable in Python?

Tuple

List

String

Set

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the purpose of the fit () method in a linear Regression model in python

To make prediction on new data

To train the model on the training data

To evaluate the model's performance

To visualize the regression line

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will math.floor(4.8) return?

5

4

4.0

5.0

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the purpose of pip in Python?

Package management

Data visualization

Debugging

Running scripts

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What does df.shape return in Pandas?

Number of rows

Number of columns

Tuple (rows, columns)

Datatype of DataFrame

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?