Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #22051

Re: Odd strip behavior

Path csiph.com!usenet.pasdenom.info!aioe.org!news.stack.nl!newsfeed.xs4all.nl!newsfeed6.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Return-Path <arnodel@gmail.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.038
X-Spam-Evidence '*H*': 0.92; '*S*': 0.00; '"if': 0.04; 'docstring': 0.16; 'received:209.85.213.174': 0.16; 'received:mail- yx0-f174.google.com': 0.16; 'subject:behavior': 0.16; 'cc:addr :python-list': 0.16; 'wrote:': 0.18; 'header:In-Reply-To:1': 0.22; 'cc:2**0': 0.26; "i'm": 0.28; 'message-id:@mail.gmail.com': 0.29; 'cc:addr:python.org': 0.29; 'pm,': 0.29; '22,': 0.30; 'none,': 0.30; 'instead.': 0.32; 'does': 0.32; 'received:google.com': 0.37; 'received:209.85': 0.38; 'characters': 0.39; 'clearly': 0.39; 'received:209': 0.39; 'march': 0.61; 'brown': 0.80; '2012,': 0.84
DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=Kik5xoGkQpYZiL/qTFDNAQE6hVpw4I9ihXSRgUu4eq0=; b=vH5Ay38sHx8BZLZIrSkUzZkqd+0dJD5iUKn7st75ydzvib95r/NBEhE174mXQuEYAz s6bu9pg4jbTziqqFB3VW01jF1MzmoY0fcZAAR0ZnvU6NqTzOr5V8X4xx2t1aDc+kKvrg +P3j7IFoTpFTIhf6GHvPZ6qAiPGPyrsUEEH1z0p7y8o8Z/Cdw9DB6t9FkTfmHKdD4o3S zL3SPTGWA3mIv3/ds/+XILiw+g7BHw690lRscch+Z8ZGxxKS51IWI08Z7S72ZKEzCIbe 54+SKrh1hRoj7IWbxX9PR2ZStrOmme+l7g6mGf8BQN6Xt+HQCjbAbWzS78jIAMTflQaF wrDg==
MIME-Version 1.0
In-Reply-To <775DE2D7-B96D-49F5-B6EA-B58BEE1B7F80@gmail.com>
References <5B2CBFB0-DC2D-47E1-978F-59E47EB3A757@gmail.com> <CAJ6cK1a_D-OypQbJsBEfTJeY-JqmK3F4pdLBS2pKmg0UaH0E_g@mail.gmail.com> <775DE2D7-B96D-49F5-B6EA-B58BEE1B7F80@gmail.com>
Date Thu, 22 Mar 2012 20:18:22 +0000
Subject Re: Odd strip behavior
From Arnaud Delobelle <arnodel@gmail.com>
To Rodrick Brown <rodrick.brown@gmail.com>
Content-Type text/plain; charset=UTF-8
Cc "python-list@python.org" <python-list@python.org>
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.12
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <http://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <http://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.910.1332447504.3037.python-list@python.org> (permalink)
Lines 15
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1332447504 news.xs4all.nl 6901 [2001:888:2000:d::a6]:57757
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:22051

Show key headers only | View raw


On 22 March 2012 20:04, Rodrick Brown <rodrick.brown@gmail.com> wrote:
>
> On Mar 22, 2012, at 3:53 PM, Arnaud Delobelle <arnodel@gmail.com> wrote:
> Try help(ste.strip)
>
> It clearly states "if chars is given and not None, remove characters in
> chars instead.
>
> Does it mean remove only the first occurrence of char? That's the behavior
> I'm seeing.

The key words in the docstring are "leading and trailing"

-- 
Arnaud

Back to comp.lang.python | Previous | Next | Find similar | Unroll thread


Thread

Re: Odd strip behavior Arnaud Delobelle <arnodel@gmail.com> - 2012-03-22 20:18 +0000

csiph-web