Reputation: 31
So I have a List of Chars [, , ] as example, but I want it to be ["","",""]
How can I make this happen? All I find on the Internet is how to convert a list to a string, but as I said that's not what I want. Any help?
Thanks in advance
Upvotes: 3
Views: 530
Reputation: 58
You only have to use the map function on the list:
val strings = listOf('a','b').map{it.toString()}
print(strings)
Upvotes: 3