Unit 1 Review: Python Basics

Unit 1 Review: Python Basics

Assessment

Flashcard

Computers

9th - 12th Grade

Practice Problem

Hard

Created by

Wayground Content

FREE Resource

Student preview

quiz-placeholder

18 questions

Show all answers

1.

FLASHCARD QUESTION

Front

Given the following string: h = "Hello", which code results in an error? Options: print (h), print(h.lower()), h = 's', print(h+1)

Back

print(h+1)

2.

FLASHCARD QUESTION

Front

What is the output of the following code?

Media Image

Back

An error message

3.

FLASHCARD QUESTION

Front

What does the input() function return? Options: an integer value, a string value, a float value, all of the above

Back

a string value

4.

FLASHCARD QUESTION

Front

What is the value of x after the following code is run?

Media Image

Back

22

5.

FLASHCARD QUESTION

Front

Which statement sets the variable t to a value of "Total Credits: 25"? Options: t = "Total Credits:" + 25, t = "Total Credits:" + str(25), t = input("Total Credits:" + str(25)), print("Total Credits", "25")

Back

t = "Total Credits:" + str(25)

6.

FLASHCARD QUESTION

Front

What is "print" used for?

Back

To display output

7.

FLASHCARD QUESTION

Front

What is the output of the following code?
print("He said, \"I'm coming to school tomorrow.\"")

Back

He said, "I'm coming to school tomorrow."

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?