[Tutor] replacing something on last line
Andrei Kulakov
ak@silmarill.org
Mon, 8 Jul 2002 03:17:33 -0400
On Mon, Jul 08, 2002 at 12:41:51AM -0400, Paul Tremblay wrote:
> On Sun, Jul 07, 2002 at 04:32:46PM -0400, Andrei Kulakov wrote:
>
> > Reverse, change first, reverse again and write?
> >
>
> Could you give me an example? I am not sure how to use the reverse fuction or method.
>
rfind from another post is more straighforward.. but you could also use
reverse method of lists: my_list.reverse(). List could be a list of
lines in files or a list of words in that line (you'd have to use
split() string method).
>
> Thanks
>
> Paul
>
> --
>
> ************************
> *Paul Tremblay *
> *phthenry@earthlink.net*
> ************************
>
>
> _______________________________________________
> Tutor maillist - Tutor@python.org
> http://mail.python.org/mailman/listinfo/tutor
>
>
--
Cymbaline: intelligent learning mp3 player - python, linux, console.
get it at: cy.silmarill.org