Concat array values Languages

Concat array values

I have this string :I want to get :I tried to do this : var string = 'Item 1Item 2Item 3Item 4' var regex = string.split(/(/d)/) regex.splice(-1, 1) regex[regex.length - 2] += regex[regex.length - 1]; regex.splice(-1, 1) console.log(regex);
Read More