[Tutor] How to strip both single and double quotes

Dick Moores rdm at rcblue.com
Wed Oct 5 14:53:55 CEST 2005


Alan Gauld wrote at 04:38 10/5/2005:
> > how to use strip just once to get rid of both kinds of quotes, single 
> and
> > double. It seems necessary to do it something like this:
>
>JUst escape the quote character:
>
>s.strip('\'"')

That did it!

Thanks,

Dick Moores



More information about the Tutor mailing list