Python If ... Else

Python If ... Else

Assessment

Flashcard

Other

12th Grade

Practice Problem

Hard

Created by

Wayground Content

FREE Resource

Student preview

quiz-placeholder

10 questions

Show all answers

1.

FLASHCARD QUESTION

Front

What does the 'if' keyword in Python signify?

Back

Start of a conditional statement

2.

FLASHCARD QUESTION

Front

What operator is used in Python to check if two values are equal?

Back

==

3.

FLASHCARD QUESTION

Front

Which keyword is used in Python to define an alternative condition if the initial 'if' condition is not met?

Back

elif

4.

FLASHCARD QUESTION

Front

What is the output of the conditional statement if 'a = 33' and 'b = 200' and the condition is 'if b > a'?

Back

'b is greater than a'

5.

FLASHCARD QUESTION

Front

What does Python use to define the scope of a block of code?

Back

Indentation

6.

FLASHCARD QUESTION

Front

What keyword is used to reverse the result of a conditional statement in Python?

Back

not

7.

FLASHCARD QUESTION

Front

In Python, what does the 'and' keyword do?

Back

Combines two conditional statements

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

Already have an account?