Spot the bug JavaScript
1
// Parse the quantity column from a CSV row.
2
const raw = ["10", "7", "11", "3"];
3
const quantities = raw.map(parseInt);
4
console.log(quantities);
5
// expected: [ 10, 7, 11, 3 ]
6
// actual: [ 10, NaN, 3, NaN ] (!)