Search
The pipe, |, allows us to match one of several patterns defined within /.../.
|
/.../
This code defines a regular expression pattern regexPipe which matches either cat or dog in a string.
regexPipe
cat
dog