Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #97280
| Date | 2015-10-01 07:39 -0500 |
|---|---|
| From | Tim Chase <python.list@tim.thechases.com> |
| Subject | Re: Question about regular expression |
| References | <811788b6-9955-4dcc-bf49-9647891d17ec@googlegroups.com> <20150930142015.4045c931@bigbox.christie.dr> <muib0r$uhn$1@ger.gmane.org> <CANN3ufk8O1gBnmZ7ZAnGYjQNG56xwyuUNCqUz8VD350TUmuBSg@mail.gmail.com> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.291.1443703705.28679.python-list@python.org> (permalink) |
On 2015-10-01 01:48, gal kauffman wrote:
> items = s.replace(' (', '(').replace(', ',',').split()
s = "name1 (1)"
Your suggestion doesn't catch cases where more than one space can
occur before the paren.
-tkc
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Question about regular expression massi_srb@msn.com - 2015-09-30 11:34 -0700
Re: Question about regular expression Emile van Sebille <emile@fenx.com> - 2015-09-30 11:50 -0700
Re: Question about regular expression Tim Chase <python.list@tim.thechases.com> - 2015-09-30 14:20 -0500
Re: Question about regular expression Denis McMahon <denismfmcmahon@gmail.com> - 2015-09-30 23:30 +0000
Re: Question about regular expression Denis McMahon <denismfmcmahon@gmail.com> - 2015-10-02 18:25 +0000
Re: Question about regular expression Emile van Sebille <emile@fenx.com> - 2015-09-30 20:58 -0700
Re: Question about regular expression Tim Chase <python.list@tim.thechases.com> - 2015-10-01 07:39 -0500
Re: Question about regular expression Rob Gaddi <rgaddi@technologyhighland.invalid> - 2015-10-01 15:53 +0000
Re: Question about regular expression Denis McMahon <denismfmcmahon@gmail.com> - 2015-10-01 21:41 +0000
Re: Question about regular expression Denis McMahon <denismfmcmahon@gmail.com> - 2015-10-01 21:31 +0000
csiph-web