They only let you match any single character. Many times, it's useful to match specified characters from a list. For example, if you have an input text that contains chapter headings that are expressed numerically as Chapter 1, Chapter 2, etc, you might want to find those chapter headings. When characters are enclosed in brackets, the list is called a bracket expression . Within brackets, as anywhere else, ordinary characters represent themselves, that is, they match an occurrence of themselves in the input text.
Most special characters lose their meaning when they occur inside a bracket expression.
Characters enclosed in a bracket expression match only a single character for the position in the regular expression where the bracket expression appears. The bracket expression then, is used to specify only the set of characters that matches the single character position immediately following the word 'Chapter' and a space. That is the ninth character position. The character value of the individual characters determines their relative order within a range. The following JScript regular expression contains a range expression that is equivalent to the bracketed list shown above.