`Pattern` is a trait for inputs used to search strings. For example, `.match_indices()` accepts a string slice, a character, or a closure as its search pattern. It returns each match together with its index. section 9.1.4
One search uses a closure to find characters; the other uses a string slice to find repeated punctuation. Both use `.match_indices()` to print matches and their indexes. section 9.1.4
You do not need to implement or inspect the trait to use these examples. The word “pattern” also appears in tuple destructuring and `match` arms; those examples concern matching values, not choosing a string-search input. section 9.1.4 section 3.1.3 section 3.2.2
