I think you might do well to read a regex tutorial; there are many, but I like this one in the Java Tutorials. Try the “character classes” section. I think you are correct that the two regexes are equivalent to each other.
Are you implying that the && has no use? Limited use maybe (I have only used it a few of times in over 20 years of using regex) but it does have uses. I can only remember using it in a negative context when wanting to exclude characters from a character set. For example -
This will create an alpha set excluding P and t.
Joined: Jan 01, 2012
@Richard Tookey yeah , it could be used to subtract characters from a particular range , that's what I thought too.
@Campbell Ritchie thanks for the suggestion
Joined: Oct 13, 2005
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com
subject: Difference between regular expressions "[0-8&&[4-6]] and [4-6]"