반응형
접두어, 접미어 확인
var derrickName = "derrick"
print(derrickName.hasPrefix("der"))
print(derrickName.hasSuffix("ick"))
대소문자 변환
var convertedString: String = ""
convertedString = derrickName.uppercased()
print(convertedString)
convertedString = derrickName.lowercased()
print(convertedString)
반응형
'iOS > Swift' 카테고리의 다른 글
Property and Method (0) | 2020.12.06 |
---|