Demonstration to use join() method to convert array to string
An array in javascript can hold many any types of data that is available in the language. join() toString() Loop; 1. join() The join() method is an in-built function in JavaScript which converts the array of elements into a string separated by commas. var A = ['Sunday','Monday','Tuesday','Wednesday','Thursday'] array = A + "" That's it Now A is a string. But, JavaScript arrays are best described as arrays. :) Share.