What's the Definition of Operator in Computer Language?
in js, comma , is an operator, but not the comma in array. here's the spec ECMAScript 2015 §ECMAScript Language: Expressions#sec-comma-operator
the equal character =, such as
x = 4, is also an operator. But it could just be said as syntax.
new Date(), and
delete obj.prop and
typeof obj, and
prop in obj,
are all considered as operators in js spec.
ternary if expression
(test ? true_expr : false_expr),
ECMAScript 2015 §ECMAScript Language: Expressions#sec-conditional-operator
var x; is considered a statement.
ECMAScript 2015 §ECMAScript Language: Statements and Declarations#sec-ecmascript-language-statements-and-declarations
there does not seem to be a absolute definition that qualify something to be operator or just syntax or “statement”.