[Tutor] Still searching in html files

2010-01-21 Thread Paul Melvin
Hi, I am still looking for information in these files and have a sort of 'clunky' solution that I would like feedback on please. The code is at http://python.codepad.org/S1ul2bh7 and the bit I would like some advice on is how to get the sorted data and where to put it. Currently I use a

[Tutor] Searching in a file

2010-01-15 Thread Paul Melvin
Hi, Thanks very much to all your suggestions, I am looking into the suggestions of Hugo and Alan. The file is not very big, only 700KB (~2 lines), which I think should be fine to be loaded into memory? I have two further questions though please, the lines are like this:

[Tutor] Searching in a file

2010-01-13 Thread Paul Melvin
Hi, I have a file generated from a webpage. I want to search that file for a specific keyword, in my case 'NEW'. Once I have found that keyword I want to retrieve information below it, e.g. web link, size of file etc. When I have this information I move off until I find another 'NEW' and the pr

Re: [Tutor] Classes v2, thoughts/suggestions please

2008-07-12 Thread Paul Melvin
> -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On > Behalf Of Alan Gauld > Sent: 12 July 2008 18:08 > To: tutor@python.org > Subject: Re: [Tutor] Classes v2, thoughts/suggestions please > > > "Paul Melvin" <[EMAIL PROTECT

[Tutor] Classes v2, thoughts/suggestions please

2008-07-12 Thread Paul Melvin
Thanks to Alans insights i have come up with a working class for a square, overcomplicated probably but it lays the groundwork for my polygon class which will iterate over something to generate an n-sided polygon. If anyone is interested in actually running/testing this you need to get hold of pgyl

Re: [Tutor] General design question

2008-07-02 Thread Paul Melvin
> -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On > Behalf Of Lie Ryan > Sent: 02 July 2008 16:31 > To: tutor@python.org > Subject: Re: [Tutor] General design question (Tim Golden) > > > If I have a set of numbers, or strings etc. which have been > generated > > a

[Tutor] General design question

2008-07-02 Thread Paul Melvin
Hi, I am new to python and although have done basic many, many years ago it has all gone, replaced by rubbish! My question is this: If I have a set of numbers, or strings etc. which have been generated and I then want to do something with them, for example a sum function call. Is the b