Operators

  • Operators let you create expressions
  • Operators take 1-3 values
  • You can build pretty complex expressions (with order of operations)
const a = 1;
const b = a + 2;
let c = a * 3 - b;
c++;
const d = "The answer is: " + c;
const e = true;
const f = !e;
const g = f ? a : b
const h = c > b
const i = { first: "Bob" };
const j = "last" in i;

7 / 19