Other Resources:
Using character range in a character classe [a-z]
What is a character range in a character class? How to specify a character range in a character class in a regular expression?
I have a string of hexadecimal digits, 46594963656E7465722E636F6D and want to use character ranges in a character class to validate it.
✍: FYIcenter.com
A character range defines a set of possible characters of an ASCII code range using '-' between the first and the last character of the range in a character class.
Here are some examples of character ranges:
[0-9] # same as [0123456789] [A-F] # same as [ABCDEF]
If '-' is the first or last character in a character class, it is treated as an ordinary character.
The regular expression to a match a string of hexadecimal digits is:
[0-9a-fA-F]
[ - begin of a character class
0-9 - character range from 0 to 9
a-f - character range from a to f
A-F - character range from A to F
] - end of a character class
2013-01-22, 0👍, 0💬
Popular Posts:
How to capture the Soso Spider entries from Web log file? Here are some Web log file entries: 127.0....
All credit card numbers issued by JCB have 3 sets of numbers: JCB cards start with 2131 have 15 digi...
How to capture the Soso Spider entries from Web log file? Here are some Web log file entries: 127.0....
How to write a regular expression to parse key-value entries from Windows .INI files? Here is an exa...
A free online regular expression test tool that allows to try you regular expression pattern and see...