Kotlin Remova o espaço em branco
str.replace("\\s".toRegex(), "")
Obedient Octopus
str.replace("\\s".toRegex(), "")