I am trying to match the input
string with range of values and getting PatternSyntaxException. below is my code
output: true
But when i try to give range in double digits, it throws exception. What if i have to match a number(as string) between 10 to 25 or like that.
Output:
Exception in
thread "main" java.util.regex.PatternSyntaxException: Illegal character range near index 5
0[14-16]
^