Skip to content

Instantly share code, notes, and snippets.

@j-nordell
Last active November 6, 2017 13:57
Show Gist options
  • Save j-nordell/f369289060fc477b0de00b19571621ca to your computer and use it in GitHub Desktop.
Save j-nordell/f369289060fc477b0de00b19571621ca to your computer and use it in GitHub Desktop.
Introduction of for loop
cookie_jar = ["chocolate chip", "oatmeal raisin", "ginger",
"peanut butter", "sugar", "Oreo"] # I have these cookies in my cooke jar
for cookie in cookie_jar: # Take every cookie in the jar one by one,
print(f"The {cookie} cookie was delicious!") # and take a bite!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment