So, I have a list of bundles of alphanumeric elements such as ...
"123456"
"alpha"
"tango"
"beta"
...
I was looking to use Collections.sort()to sort this list, but I need to sort first in order (1234,AAAA,aaaa,BBBB,bbbb,...)with numbers, and then upper and lower case words. All elements are strings, including any visible numbers. Will Collections.sort()this case be handled since all of them are actually strings, or if not what ComparatorI would use for this? Or is there another way that might be more efficient for this, for example, using regular expressions?
Thank.
source
share