On 2021-12-08 23:17, Stefan Ram wrote:
Cameron Simpson <c...@cskk.id.au> writes:
Instead, consider the \b (word boundary) and \w (word character)
markers, which will let you break strings up, and then maybe test the
results with str.isupper().
Thanks for your comments, most or all of them are
valid, and I will try to take them into account!
Regexps might have their disadvantages, but when I use them,
it is clearer for me to do all the matching with regexps
instead of mixing them with Python calls like str.isupper.
Therefore, it is helpful for me to have a regexp to match
upper and lower case characters separately. Some regexp
dialects support "\p{Lu}" and "\p{Ll}" for this.
If you want "\p{Lu}" and "\p{Ll}", have a look at the 'regex' module on
PyPI:
https://pypi.org/project/regex/
[snip]
--
https://mail.python.org/mailman/listinfo/python-list