JavaScript Operators and Expressions

JavaScript Operators and Expressions

Performing Operations and Calculations

Author
Nguyen Bao Huy
17:27:00 08/02/2026
1 min read
0 comments

The Addition Operator + adds numbers. The Assignment Operator = assigns a value to a variable.

Operator JavaScript
Operator JavaScript

JavaScript Assignment

The Assignment Operator (=) assigns a value to a variable:

javascript
let x = 10; 
// Assign the value 5 to x
let x = 5;
// Assign the value 2 to y
let y = 2;
// Assign the value x + y to z:
let z = x + y;

JavaScript Addition

The addition Operator (+) adds numbers:

javascript
let x = 5; 
let y = 2; 
let z = x + y; 

JavaScript Multiplication

The Multiplication Operator (*) multiples numbers:

javascript
let x = 5;
let y = 2;
let z = x * y;

Types of JavaScript Operators

There are different types of JavaScript operators:

  • Arithmetic Operators
  • Assignment Operators
  • Comparison Operators
  • String Operators
  • Logical Operators
  • Bitwise Operators
  • Ternary Operators
  • Type Operators

JavaScript Arithmetic Operators

Arithmetic Operators are used to perform arithmetic on numbers:

javascript
let a = 3;
let x = (100 + 50) * a;

First Lesson

You are at the beginning of this curriculum.

Latest Tutorial

More chapters coming soon to this topic.

Author avatar

Nguyen Bao Huy

Lead Fullstack & AI Solutions Engineer

Specializing in Next.js App Router, React 19, TypeScript, and modern design systems. Passionate about creating seamless user experiences.

Discussion

0

No comments yet

Be the first to share your thoughts, question a concept, or provide additional tips!

Leave a Reply

Share your insights, questions, or solutions with the developer community.

Your avatar
0 / 500 characters