Hi, I have a text file with a few 1000 lines of text in it. A sample is given below:
person1
person2
person3
person4
have paid
---------
person5
person6
person7
person9
person10
person11
have paid
---------
Each line starts with either "p" or "h" or "-". When "have paid" is encountered while reading the file, I want to append the previous two lines into a list so that I can differentiate people who have paid and people who have not paid. Any help?
Cheers, Chav