I've got a very simple calculator app:
if (process.argv[3]==='+') console.log(parseInt(process.argv[2]) + parseInt(process.argv[4]));
if (process.argv[3]==='-') console.log(parseInt(process.argv[2]) - parseInt(process.argv[4]));
if (process.argv[3]==='*') console.log(parseInt(process.argv[2]) * parseInt(process.argv[4]));
if (process.argv[3]==='/') console.log(parseInt(process.argv[2]) / parseInt(process.argv[4]));
console.log(process.argv[3])
2 + 2, 2 - 2, 2 / 2 all work as expected, but 2 * 2 will log out the name of the script.
Why does this happen? What is it about the multiplication sign?