Control Flow

Estimated reading: 1 minute 12 views

Control Flow

Use control flow statements to make decisions in your program. The if, elif, and else statements help control the flow of execution.

# Control Flow
x = 10

if x > 0:
    print("Positive")
elif x < 0:
    print("Negative")
else:
    print("Zero")
Share this Doc

Control Flow

Or copy link