Mastery18

Nesting of conditional statements

If you want to check a condition after a previous condition that was true, then you might want to use nested statements.

Example:

NESTED IF CONSTRUCT

In a nested if construct, you can have an if…elif…else construct inside another if…elif…else construct. The syntax of the nested if…elif…else construct may be:

18 1014

CC BY 4.0 Mastery18 by Joel Erles is licensed under a Creative Commons Attribution 4.0 International License.

Comments are closed.