Kotlin/문법
Kotlin - replace()
내손은개발 🐾
2024. 2. 2. 16:40
replace
- 공백 제거 및 특정 문자열 반환
var str = "hello world"
println(str.replace(" ","")) //helloworld
println(str.replace("world","hi")) //hellohi