3 Respostas
+ 1
It's short for "else if".
if "condition":
#code
elif "condition":
#code
else:
#code
0
Elif in python is Else if and we use it if we have multiple conditions
For a simple exemple:
a = input()
b = input()
if a > b:
print("a is greater than b")
elif b > a:
print("b is greater than a")
else:
print("both a and b are equal")