Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #22045
| Path | csiph.com!usenet.pasdenom.info!gegeweb.org!de-l.enfer-du-nord.net!feeder2.enfer-du-nord.net!feeds.phibee-telecom.net!newsfeed.xs4all.nl!newsfeed5.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail |
|---|---|
| Return-Path | <rodrick.brown@gmail.com> |
| X-Original-To | python-list@python.org |
| Delivered-To | python-list@mail.python.org |
| X-Spam-Status | OK 0.042 |
| X-Spam-Evidence | '*H*': 0.92; '*S*': 0.00; 'main()': 0.05; '__name__': 0.09; 'def': 0.13; 'to:name:python-list@python.org': 0.15; "'__main__':": 0.16; 'main():': 0.16; 'subject:behavior': 0.16; 'print': 0.29; 'message-id:@gmail.com': 0.31; 'skip:# 10': 0.34; 'to:addr:python-list': 0.35; 'charset:us-ascii': 0.37; 'received:google.com': 0.37; 'received:209.85': 0.38; 'received:209': 0.39; 'to:addr:python.org': 0.40; 'header:Message- Id:1': 0.62; 'iphone': 0.68; 'received:209.85.216.174': 0.80 |
| DKIM-Signature | v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=subject:from:content-type:x-mailer:message-id:date:to :content-transfer-encoding:mime-version; bh=zbZwAEBOsi4lfDH7ILaL1RU1LRluS8Ko1nrfb8i1Ux8=; b=Wt9cNvgEugo3PWcnPEknNgl3WeYz/xYeR46tHTXWd2mcR/A5rSy+j0wuYrAqMiJfkK OKMNPkBPnbN/BWH+XDt2h3UyFJDJlktlZacGOi3Mn2vR4AcjBAIS8bmf9HkQ6E7cKY28 898uiIBWRWHi6iKHwlmBmiN8L2cZZ6rWjuyCijisJOcyEL3A8TLIL0+yoTNes6pK82DM WRxtTgmUQiebylLsLDK4GFdtVL+8M93WL2NDu5OYM4DY/zx+QaK8AHAxEDHB/7bQ4FwI 9l8BsPmlaUfexgH94A64dQo5aLXR/4+UuKLa3a/Iinghsmbkr0eH76urQoeeiyKbyHiP y3cA== |
| Subject | Odd strip behavior |
| From | Rodrick Brown <rodrick.brown@gmail.com> |
| Content-Type | text/plain; charset=us-ascii |
| X-Mailer | iPhone Mail (9A405) |
| Date | Thu, 22 Mar 2012 15:48:44 -0400 |
| To | "python-list@python.org" <python-list@python.org> |
| Content-Transfer-Encoding | 7bit |
| Mime-Version | 1.0 (1.0) |
| 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.903.1332445730.3037.python-list@python.org> (permalink) |
| Lines | 19 |
| NNTP-Posting-Host | 2001:888:2000:d::a6 |
| X-Trace | 1332445730 news.xs4all.nl 6911 [2001:888:2000:d::a6]:55445 |
| X-Complaints-To | abuse@xs4all.nl |
| Xref | csiph.com comp.lang.python:22045 |
Show key headers only | View raw
#!/usr/bin/python
def main():
str1='this is a test'
str2='t'
print "".join([ c for c in str1 if c not in str2 ])
print(str1.strip(str2))
if __name__ == '__main__':
main()
./remove_str.py
his is a es
his is a tes
Why wasnt the t removed ?
Sent from my iPhone
Back to comp.lang.python | Previous | Next — Next in thread | Find similar | Unroll thread
Odd strip behavior Rodrick Brown <rodrick.brown@gmail.com> - 2012-03-22 15:48 -0400 Re: Odd strip behavior Kiuhnm <kiuhnm03.4t.yahoo.it> - 2012-03-22 20:56 +0100
csiph-web