Created
August 19, 2014 04:40
-
-
Save dukenmarga/9183706675ad5e87e8de to your computer and use it in GitHub Desktop.
read file line per line and trim new line symbol
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
file = 'fileName' | |
f = open(file, 'r') | |
content = f.readlines() | |
size = len(content) | |
for i in range(size): | |
print content[i].rstrip() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment