[ AEEP2301 ] 3.1 - Making Decisions in Python

0.0(0)
Studied by 0 people
call kaiCall Kai
Locked
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/34

encourage image

There's no tags or description

Looks like no tags are added yet.

Last updated 5:43 PM on 9/25/26
Name
Mastery
Learn
Test
Matching
Spaced
Call with Kai
Chat

No analytics yet

Send a link to your students to track their progress

35 Terms

1
New cards

Assigning a value to a variable.

What does = mean in Python?

2
New cards

Either True or False.

What will the output of a conditional operator always be?

3
New cards

Whether the left side and right side are equal to each other.

What does == check?

4
New cards

Whether the left side and right side are not equal to each other.

What does != check?

5
New cards

Whether the left side is greater than the right side.

What does > check?

6
New cards

Whether the left side is less than the right side.

What does < check?

7
New cards

Whether the left side is greater than or equal to the right side.

What does >= check?

8
New cards

Whether the left side is less than or equal to the right side.

What does <= check?

9
New cards

= assigns a value; == checks if two values are equal.

What is the difference between = and ==?

10
New cards

True, because both values are equal.

What does 2 == 2 produce?

11
New cards

A keyword that has a specific meaning in Python and cannot be used as a variable name.

What is a reserved keyword?

12
New cards

if, elif, and else.

Which conditional keywords cannot be used as variable names?

13
New cards

if condition: followed by an indented instruction.

What is the basic syntax of an if statement?

14
New cards

A colon :.

What must come after the condition in an if statement?

15
New cards

Indentation.

What must be used before the instruction inside an if statement?

16
New cards

There will not be any output, not even a False.

What happens if an if condition is false?

17
New cards

Yes, as long as they have the same indentation.

Can more than one instruction be written inside an if statement?

18
New cards

To show that they belong to the same if block.

Why must multiple instructions inside an if statement have the same indentation?

19
New cards

if must come first and else must come after it.

What order must if and else follow?

20
New cards

No. No condition is written after else.

Does else have a condition?

21
New cards

The instruction inside the if block is executed.

What happens when the if condition is true in an if-else statement?

22
New cards

To check more than one condition.

Why is an if-elif-else statement used?

23
New cards

Yes, there can be as many elifs as needed.

Can there be more than one elif?

24
New cards

Its instruction is executed, and Python stops checking the conditions below it.

What happens when the first condition in an if-elif-else statement is true?

25
New cards

They are not checked or executed.

What happens to the conditions below the first true condition?

26
New cards

The first condition Python checks that evaluates to True.

What does “the first true condition” mean?

27
New cards

Only one branch, the first true branch.

How many branches are executed in one if-elif-else statement?

28
New cards

The else branch is executed.

What happens if none of the if or elif conditions are true?

29
New cards

Having another if/elif/else statement inside an if/else statement.

What is a nested conditional statement?

30
New cards

Inside the instructions of another conditional statement.

Where can another conditional statement be placed in a nested conditional?

31
New cards

One conditional statement is placed inside another conditional statement.

What does “nested” mean in conditional statements?

32
New cards

Indentation.

What determines which instructions belong to a conditional block?

33
New cards

No. It executes only the first true condition.

In an if-elif-else statement, does Python execute every true condition?

34
New cards

It stops the operation and does not look at anything below the true condition.

What happens after Python executes the first true condition?

35
New cards

Only one output/branch is executed.

What is the key rule to remember about each if-elif-else statement?