RosettaCodeData/Task/String-matching/PowerShell/string-matching.ps1
2026-04-30 12:34:36 -04:00

5 lines
169 B
PowerShell

"spicywiener".StartsWith("spicy")
"spicywiener".Contains("icy")
"spicywiener".EndsWith("wiener")
"spicywiener".IndexOf("icy")
[regex]::Matches("spicywiener", "i").count