E-Ching
0
Q:

convert array to number

// CONVERT ARRAY STRING TO ARRAY NUMBER
const arrStr = ["1", "3", "5", "9"];
const nuevo = arrStr.map((i) => Number(i));
console.log(nuevo);
// [1,3,5,9];
1
let x = [1,2,3,4,5]
let num = +x.join("")
1
int i, k = 0;
for (i = 0; i < n; i++)
    k = 10 * k + a[i];
0

New to Communities?

Join the community