|
- param($inputString)
- $words = $inputString.Split('_')
- $outputString = ""
- foreach ($word in $words) {
- $outputString += $word.Substring(0,1).ToUpper() + $word.Substring(1).ToLower() + ""
- }
- $outputString = $outputString.TrimEnd()
- $outputString -replace ' ', '' # 如果想要没有空格的字符串,取消注释这行代码
- $outputString
|