Operator Scope of Action:
Operator First Added:
The operator returns the first matched subexpression of a regular expression patten in the source String. If the regular expression has no subexpressions, the entire match is returned.
For example, take a String which is the $Text "We are very tired, Harrison! #things #Memes #August":
$MyString = $Text.extract([A-Z][A-Za-z+]);
this returns "We" as that is the first match (although there are others). This sort of use is the presumed most likely used of this operator.
If we amend the regex
$MyString = $Text.extract(#([A-Z][A-Za-z+]));
it now returns "Memes" (the first hash tag starts with a lowercase letter does not match).