The following example will let you know how you can define separator and how many ways you can convert array into the string list.Array join() method
You can use join method that will join the array elements into the new string. By default array elements are separated with a (",") comma separator.Syntax:
You can also pass the separator in join method to convert array with specified separator.
array.join(", ")Example Array toString() method
You can also use
toString method to convert array into a string. It will return a string, separated by a comma.