+1

Kotlin doubt on Array import

Hi sir, I'm new to coding i dont no what to import to avoid error in following code... Please help me! https://code.sololearn.com/c7sg4O2sA9op/?ref=app

10/10/2019 6:54:51 AM

KAAMIL AHAMADH S

1 Answer

New Answer

+3

x.toString() would avoid the import, but you won't like the output. x.joinToString(", ","[","]") will get a formated list. Parameters: string between values, string to start with, and string to end with. There are more and they all have default values so none need to be used.