Case-insensitive string equality
Serhiy Storchaka
storchaka at gmail.com
Thu Aug 31 03:51:19 EDT 2017
31.08.17 10:10, Steven D'Aprano пише:
> (iii) Not every two line function needs to be in the standard library.
> Just add this to the top of every module:
>
> def equal(s, t):
> return s.casefold() == t.casefold()
This is my answer.
> Unsolved problems:
>
> This proposal doesn't help with sets and dicts, list.index and the `in`
> operator either.
This is the end of the discussion.
More information about the Python-list
mailing list