python

Python if-elif-else Statements

BEGINNER

#python

Author: Alina Myronets

Course description

This mini-course is designed to introduce you to all the nuances of the conditional operator if-else. The course is filled with examples to better understand the use of such an operator, as well as tasks to consolidate the acquired skills. Here you will also get acquainted with the if-elif-else statements.

info

Complete all chapters to get certificate

0%

Python if Statement

chevron

Here we get acquainted with the simplest representations of the conditional operator if. In addition, we get acquainted with the use of logical operators and the priorities for their use, after which we consolidate the knowledge of practice.

Introduction to if Statement

Syntax of if Statement

Challenge

Operators

Logical Operators 1/2

Logical Operators 2/2

Python if-else Statement

chevron

In this section, we are introduced to a more advanced form of the conditional operator - if-else. We will also learn what nested if-else statements are and practice on tasks.

Introduction to if-else Statement

Syntax of if-else Statement

Nested if-else Statement

Challenge 1

Challenge 2

Python if-elif-else Statement

chevron

At the end of the course, we will learn about the most advanced form of the conditional operator if-elif-else, get acquainted with the syntax of this construction and how it is applied correctly.

Introduction to if-elif-else Statement

Challenge 1

Challenge 2

Divide the List into Three Lists, Following Certain Conditions