I'm trying to read a text file with a blank line at the end of it, and I need to put those lines into a list.
The text file looks something like this:
this is the first line
this is the second line
*
(* is indicating a blank line)
i read the textfile like this:
read_str = file.readlines()
print(read_str)
It gives me the list I want, which is good, but at the end it says "None". Like this:
['this is the first line\n', 'this is the second line\n']
None
Why is it giving me "None" at the end, and how can I fix this?