for examplethe character class [ -za- - will match all lowercase lettersuppercase lettersand numbers note that inside the square bracketsthe normal regular expression symbols are not interpreted as such this means you do not need to escape the *?or (characters with preceding backslash for examplethe character class [ - will match digits to and period you do not need to write it as [ - by placing caret character (^just after the character class' opening bracketyou can make negative character class negative character class will match all the characters that are not in the character class for exampleenter the following into the interactive shellconsonantregex re compile( '[^aeiouaeiou]'consonantregex findall('robocop eats baby food baby food '[' '' '' '' ''' '' ''' '' '' ''' '' '''' '' '' ''' '' ''nowinstead of matching every vowelwe're matching every character that isn' vowel the caret and dollar sign characters you can also use the caret symbol (^at the start of regex to indicate that match must occur at the beginning of the searched text likewiseyou can put dollar sign ($at the end of the regex to indicate the string must end with this regex pattern and you can use the and together to indicate that the entire string must match the regex--that isit' not enough for match to be made on some subset of the string for examplethe '^helloregular expression string matches strings that begin with 'helloenter the following into the interactive shellbeginswithhello re compile( '^hello'beginswithhello search('helloworld!'beginswithhello search('he said hello '=none true the '\ $regular expression string matches strings that end with numeric character from to enter the following into the interactive shellendswithnumber re compile( '\ $'endswithnumber search('your number is 'endswithnumber search('your number is forty two '=none true