34,333
edits
Changes
→The switch $_ Variable
== The switch $_ Variable ==
When a switch is operating, the value being evaluated for a match is assigned to a special variable referenced by ''$_''. This is provided so that the value may be accessed within the body of the switch construct. This is of particular use when using the ''expressions '' in a switch statement as described in the following section.
== Using Expressions in a Windows PowerShell switch Statement ==