John Fouhy schrieb:
> On 02/11/06, Chris Hengge <[EMAIL PROTECTED]> wrote:
> myStr = "I want to strip my words."
> print myStr.strip("my")
> 'I want to strip words.'
>
> .strip() only removes text from the beginning and end of the string.
It is generally used to remove whitespace from
On 02/11/06, Chris Hengge <[EMAIL PROTECTED]> wrote:
> I can't figure out a way to .strip("string")
>
> Example might look like this:
>
> >>> myStr = "I want to strip my words."
> >>> print myStr.strip("my")
> >>> 'I want to strip words.'
.strip() only removes text from the beginning and end of th
I can't figure out a way to .strip("string")Example might look like this:>>> myStr = "I want to strip my words.">>> print myStr.strip("my")>>> 'I want to strip words.'
Thanks.
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo