| Regular expression: | ||
| Test string: | ||
| ^ | start of line | |
| $ | end of line | |
| . | any symbol | alphabet, Σ | 
| | | either | Union, ∪ | 
| * | zero or more copies | Kleene's star (...)* | 
| + | at least one copy | (...)+ | 
| abba | accepts any string with abba in it | 
| ^abba$ | accepts only one string, abba | 
| ^(10)+1$ | accepts strings of form 10101...01 | 
| ^(1|0)*1$ | accepts odd binary numbers |