<jupyter_start><jupyter_text>CONDITIONS AND BRANCHING IN PYTHON  Table of ContentsComparison Operators to make conditions Branching COMPARISON OPERATORS Comparison operations compare some value or operand and, based on a condition, they produce a Boolean. When comparing two values you can use these operators:equal: `==`not equal: `!=`greater than: `>`less than: `greater than or equal to: `>=`less than or equal to: ` Branching  Branching allows us to run different statements for different inputs. It is helpful to think of an **if statement** as a locked room, if the statement is true you can enter the room and your program will run some predefined task, but if the statement is false your program will skip the task.  For example, consider the driving licence requirement The **elif** statement,<jupyter_code>age=17
if age>17:
    
    print("you can enter" )
elif age==17:
    print("Start learning driving safely")
else:
    print("Wait" )
    

print("move on")<jupyter_output>Start learning driving safely
move on
{'fraction_non_alphanumeric': 0.0703125, 'fraction_numerical': 0.005859375, 'mean_word_length': 4.959302325581396, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '402719', 'license': 'MIT', 'n_tokens_mistral': 279, 'n_tokens_neox': 269, 'n_words': 140, 'path': 'Basics of Python/Notebooks/Python_Conditions and branching.ipynb', 'repo_name': 'VNSST/Hands_on_Machine_Learning_using_Python', 'size': '1024'}