--Originally published at Ed_Alita
The core of a program is if and else because thaey give the flow to a program therefore in order to make a program you net to know how do if and else work.
To put in python this is the rules to put it:
It has three parts the comparator and then the action this is a if context.
To do a else if comparation is the next one.
The last part is the else if the compartor does not apply it goes directly to the else.
If the condition is true:
if the cpondition is false:
Now you are a step futher in becoming a code master.
Elif
This operator is use to compare a variable to a lot of expressin if any of them is true you go to a default expression.
Put the next cod eto invoque the elif:
the result is the next one:
The material seen here is in:
https://www.tutorialspoint.com/python/python_if_else.htm