examples/files/read_file_remove_newlines.py
from __future__ import print_function

filename = 'examples/files/numbers.txt'

f = open(filename, 'r')
for line in f:
    line = line.rstrip("\n")
    print(line)
f.close()