Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
An example of a while loop in Python.
# Kino Rose
# Python While Loop example
# Initialize i
i = 0
while i < 6:
# Increment i by 1
i++
print(i) # 1, 2, 3, 4, 5
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment