November 2018
Intermediate to advanced
566 pages
17h 15m
English
There is an automatic variable, $Matches, which contains all of the matches that are found during an operation:
PS> "Hey, there! I'm using PowerShell." -match "([a-z]+)'([a-z]+)"
Calling $Matches now would list out the following:
The would be listed out as a hashtable. (You will learn more about hashtables in Chapter 9, Using Arrays and Hashtables; for now, think of them as a simple tabular representation of a list.)
Read now
Unlock full access