Re: Cutting slices

2023-03-06 Thread Christian Gollwitzer
Am 05.03.23 um 23:43 schrieb Stefan Ram: The following behaviour of Python strikes me as being a bit "irregular". A user tries to chop of sections from a string, but does not use "split" because the separator might become more complicated so that a regular expression will be required

RE: Cutting slices

2023-03-05 Thread avi.e.gross
laim is a divider? Could that be why gamma got truncated? Unless you can arrange for a terminal period, maybe you can reconsider the approach. -Original Message- From: Python-list On Behalf Of aapost Sent: Sunday, March 5, 2023 6:00 PM To: python-list@python.org Subject: Re: Cutting slice

Re: Cutting slices

2023-03-05 Thread Greg Ewing via Python-list
On 6/03/23 11:43 am, Stefan Ram wrote: A user tries to chop of sections from a string, but does not use "split" because the separator might become more complicated so that a regular expression will be required to find it. What's wrong with re.split() in that case? -- Greg -- https:

Re: Cutting slices

2023-03-05 Thread MRAB
On 2023-03-06 00:28, dn via Python-list wrote: On 06/03/2023 11.59, aapost wrote: On 3/5/23 17:43, Stefan Ram wrote:    The following behaviour of Python strikes me as being a bit    "irregular". A user tries to chop of sections from a string,    but does not use "split" because the separator m

Re: Cutting slices

2023-03-05 Thread Rob Cliffe via Python-list
On 05/03/2023 22:59, aapost wrote: On 3/5/23 17:43, Stefan Ram wrote:    The following behaviour of Python strikes me as being a bit    "irregular". A user tries to chop of sections from a string,    but does not use "split" because the separator might become    more complicated so that a regu

Re: Cutting slices

2023-03-05 Thread dn via Python-list
On 06/03/2023 11.59, aapost wrote: On 3/5/23 17:43, Stefan Ram wrote:    The following behaviour of Python strikes me as being a bit    "irregular". A user tries to chop of sections from a string,    but does not use "split" because the separator might become    more complicated so that a regula

Re: Cutting slices

2023-03-05 Thread aapost
On 3/5/23 17:43, Stefan Ram wrote: The following behaviour of Python strikes me as being a bit "irregular". A user tries to chop of sections from a string, but does not use "split" because the separator might become more complicated so that a regular expression will be required to