Here's some pseudocode:
Open the file, assign to an identifier
Start a while loop, maybe
while True:
Initialize an empty list
I am using file method
next() which raises a StopIteration exception when reaching the end of a file, so start a try/except block
Start a for loop over a range of 20
Append the next line of the file to the list using file method
next(), end of for loop
Print the list using string method join
Call
raw_input() which pauses processing
Now for the except part of the try/except block (except StopIteration:)
If there is anything in the list, print it
Break from the loop