let userInput = "2+4"; let result = Function("return " + userInput)(); // which is same as "return 2+4" console.log(result)
parseInt(3) + parseInt(3)