remove whitespaces

Solutions on MaxInterview for remove whitespaces by the best coders in the world

we are a community of more than 2 million smartest coders
registration for
employee referral programs
are now open
get referred to google, amazon, flipkart and more
register now
  
pinned-register now
showing results for - "remove whitespaces"
Jonathan
29 Jan 2021
1//Extenion function
2fun String.removeWhitespaces() = replace(" ", "")
3
4// Uses
5var str = "This is an example text".removeWhitespaces()
6
7println(str)
8
similar questions
queries leading to this page
remove whitespaces