I would like to use regex to match a string of exactly 2 characters, and both of those characters have to be between 0 and 9. The string to match against would be coming from a
You need to use anchors to match the beginning of the string ^ and the end of the string $
^
$
^[0-9]{2}$