The if statement is used for conditional execution, and it may include elif and else clauses. : If : Statement PYTHON TUTORIALS


PYTHON TUTORIALS » Statement » If »

 

The if statement is used for conditional execution, and it may include elif and else clauses.


x = 2


if x < 10:
    print 'Less than ten'
elif 10 <= x < 20:
    print 'Less than twenty'
else:
    print 'Twenty or more'



Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .


PYTHON TUTORIALS

 Navioo Statement
» If