C
Coder Guy
Is it possible to do a case insensitive comparison of individual characters?
I tried:
Char.ToLowerInvariant(charA).CompareTo(Char.ToLowerInvariant(charB))
And though it works for the most part, it didn't seem to work for all
locales.
I tried converting the characters to a string and then do a case insensitive
comparison, and this always worked. Unfortunately this comparison is being
called millions of times and converting to a string is terribly inefficient.
Do I have any other options?
Thanks
I tried:
Char.ToLowerInvariant(charA).CompareTo(Char.ToLowerInvariant(charB))
And though it works for the most part, it didn't seem to work for all
locales.
I tried converting the characters to a string and then do a case insensitive
comparison, and this always worked. Unfortunately this comparison is being
called millions of times and converting to a string is terribly inefficient.
Do I have any other options?
Thanks