.join js

JavaScript
arr.join()
arr.join(séparateur)

let monTableau = ['un', 'deux','trois', 'quatre'] ;
console.log(monTableau.join('/ ')) ;

/////////////////or//////////////////////

let monTableau2D = [
     ['Mark' , 'jeff' , 'Bill'] , 
     ['Zuckerberg' , 'Bezos' , 'Gates']
 ] ;
 
 console.log(monTableau2D[0].join(', '))
            // or 
 console.log(monTableau2D.join('/ '))

const elements = ['Fire', 'Air', 'Water'];

console.log(elements.join());
// expected output: "Fire,Air,Water"

console.log(elements.join(''));
// expected output: "FireAirWater"

console.log(elements.join('-'));
// expected output: "Fire-Air-Water"//turns array to string

const elements = ['Fire', 'Air', 'Water'];

console.log(elements.join());
// expected output: "Fire,Air,Water"

console.log(elements.join(''));
// expected output: "FireAirWater"

console.log(elements.join('-'));
// expected output: "Fire-Air-Water"

Source

Also in JavaScript: