copy a file
hackingkk at gmail.com
Tue Jul 14 09:07:13 CEST 2009
On Tue, 2009-07-14 at 12:27 +0530, amrita at iisermohali.ac.in wrote:
> Dear all,
> Can anyone tell me that suppose i want to copy few lines from one text
> file to another then how can i do that.Looking forward for soon reply.
very simple. open one file and open the source file.
seek till to the point where u want to start copying and loop till the
end with readline function.
then write it to the destination file.
To find the starting point, keep looping through the content and come
out of that loop when you find a match to the word you are looking for.
More information about the Python-list