Answers for "powershell replace regex"

0

powershell replace regex

# You can supply regular expressions to the 
# first parameter of the replace operator.

$str = "Hello world!"
$str -replace "world|earth|mars", "unspecified planetary body"

# Output: Hello unspecified planetary body!
Posted by: Guest on May-17-2021

Code answers related to "Shell/Bash"

Browse Popular Code Answers by Language