Python Boolean and If

Python Boolean and If

Assessment

Flashcard

Computers

9th - 12th Grade

Practice Problem

Hard

Created by

Wayground Content

FREE Resource

Student preview

quiz-placeholder

10 questions

Show all answers

1.

FLASHCARD QUESTION

Front

A variable that can only have two values, True or False.

Back

Boolean

2.

FLASHCARD QUESTION

Front

Which is the correct syntax? Options: has_dog = true, has_dog = True, has_dog = Treu, HAS_DOG = tRue

Back

has_dog = True

3.

FLASHCARD QUESTION

Front

What is syntax?

Back

It's a structure.

4.

FLASHCARD QUESTION

Front

Which passes a Boolean to a String? Options: print "has_dog", str(has_dog), print "has_dog" str, (input)(has_dog)

Back

str(has_dog)

5.

FLASHCARD QUESTION

Front

The choices of an if statement are called: twigs, branches, leaves, trees

Back

branches

6.

FLASHCARD QUESTION

Front

An if statement must evaluate to: True or False

Back

True or False

7.

FLASHCARD QUESTION

Front

This operator means that one value is the same as the other value

Back

==

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?