in reply to regex that simulates boolean logic
If these values are going into a config file why not list them like:
7000,7777,7778,3886200, ...
and then place them in a hash, say %not_allowed. You could then check your input using:
unless ( exists $not_allowed{ $input } ) { # do your stuff }
This may require more lines of code but would be much easier to check and understand, and also easier to edit by hand - working with a list not a regex.
|
|---|