with open(filename) as f:
    mylist = f.read().splitlines()