The mode argument indicates how the elements of the list are to be matched against pattern and it must have one of the following values:
The list element must contain exactly the same string as pattern.
Pattern is a glob-style pattern which is matched against each list element using the same rules as the string match command.
Pattern is treated as a regular expression and matched against each list element using the same rules as the regexp command.