Skip to content

Instantly share code, notes, and snippets.

@deloschang
Created April 19, 2016 20:43
Show Gist options
  • Save deloschang/821e63b1b5006069170ecdbb5e0c8b6c to your computer and use it in GitHub Desktop.
Save deloschang/821e63b1b5006069170ecdbb5e0c8b6c to your computer and use it in GitHub Desktop.
with open('http.txt') as f:
first_line = f.readline()
split_lines = first_line.split('http://')
with open('output.txt') as g:
for x in split_lines:
to_output = 'http://' + x + '\n'
g.write(to_output)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment