convert string into array of integers January 15, 2023 by Tarik A quick one for modern browsers: '14 2'.split(' ').map(Number); // [14, 2]`