I am trying to match 3 digit numbers individually except for the examples in the "should not match" list.
The current regex I have shown below does not work completely and I am not sure how to adjust it for all use cases.
Current Java Regex:
(^.*err.*[a-z].*$)|(^\d{3}$)|(^.*\d{3}\s\b$)
Test strings:
The below items should match:
-----------------------------
123
Match the number in this sentence 123 as well
999
The below items should NOT match:
---------------------------------
1234
12345
123456
1234567
£123
$456
Err404
ERR404
err404
Err 404
ERR 404
err 404
there is err 404 on page
this err 1232222222222 as well
a string 12323 like this
asd
4444333322221111
4444 3333 2222 1111
Err123
02012341234
920 1234 1234