> i am new to programming language and python. I wonder how to get a line 
> text
> from input file.

f = open('somefile.txt')
line = f.readline()

For more details on using files see the Handling Files topic in my web 
tutor.

Alan G
Author of the learn to program web tutor
http://www.freenetpages.co.uk/hp/alan.gauld


_______________________________________________
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor

Reply via email to