input record seperator (equivalent of "$|" of perl)

les_ander at yahoo.com les_ander at yahoo.com
Sun Dec 19 16:26:09 EST 2004


Hi,
I know that i can do readline() from a file object.
However, how can I read till a specific seperator?
for exmple,
if my files are

name
profession
id
#
name2
profession3
id2

I would like to read this file as a record.
I can do this in perl by defining a record seperator;
is there an equivalent in python? 
thanks




More information about the Python-list mailing list