Js an algorithm for the combination of items in an array

let arr = [1, 2, 3, 4];
(arr)
 [1, 2, 3, 4, 12, 13, 14, 23, 24, 34]
Jun.19,2022

var newArr = [];
for(var i=0;i<arr.length;iPP){
  newArr.push(arr[i]);
  for(var x=i+1;x<arr.length;xPP){
    newArr.push(arr[i]+''+arr[x]);
  }
}

var arr = [1, 2, 3, 4];
var i = [...arr];
i.forEach(value => {
  arr.shift();
  arr.forEach(v => {
    if (value != v) {
      i.push(Number('' + value + v));
    }
  })
}) //i [1, 2, 3, 4, 12, 13, 14, 23, 24, 34]
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e91dd8-5c1ab.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e91dd8-5c1ab.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?