Skip to content

Instantly share code, notes, and snippets.

@NotTheEconomist
Created January 30, 2015 00:41
Show Gist options
  • Save NotTheEconomist/c9db644566545a1dd209 to your computer and use it in GitHub Desktop.
Save NotTheEconomist/c9db644566545a1dd209 to your computer and use it in GitHub Desktop.
# this will read the file line by line
with open("path/to/file") as infile:
for line in infile:
do_something_to_the(line)
# this will see if a sequence adds up to 15
sum(some_sequence) == 15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment