join first two elements in an array js code example
Example 1: join in array
var a = ['Wind', 'Water', 'Fire'];
a.join(); // 'Wind,Water,Fire'
a.join(', '); // 'Wind, Water, Fire'
a.join(' + '); // 'Wind + Water + Fire'
a.join(''); // 'WindWaterFire'
Example 2: js array join
['h', 'e', 'y'].join('')
// hey