if the string banana is searched using the following pattern, the pattern matches banana, not ba or bana: /b.*a/ The .* character only matches the longest possible string that enables the pattern match as a whole to succeed.