AdsReg.com Magazine Logo
📌 Press Ctrl+D to bookmark this page.

Mathematical Operations

Types of JavaScript Operators

There are different types of JavaScript operators:

  1. Arithmetic Operators
  2. Assignment Operators
  3. Comparison Operators
  4. Logical Operators
  5. Conditional Operators
  6. Type Operators

Operation Table

Line Operation Description
1 + Addition
2 - Subtraction
3 * Multiplication
4 ** Exponentiation (ES2016)
5 / Division
6 % Modulus (Division Remainder)
7 ++ Increment
8 -- Decrement
Line Operator Example Same As
1 = x = y x = y
2 + x += y x = x + y
3 - x -= y x = x - y
4 * x *= y x = x * y
5 / x /= y x = x / y
6 % x %= y x = x % y
7 ** x **= y x = x ** y
       

Sample1: (+)

JavaScript/006-MathematicalOperations/001

Sample2: (-)

JavaScript/006-MathematicalOperations/002

Sample3: Make Tax Payment

JavaScript/006-MathematicalOperations/003

Sample4: String and numbers

JavaScript/006-MathematicalOperations/004

Sample5: String and numbers

JavaScript/006-MathematicalOperations/005

Sample6: BigInt

JavaScript/006-MathematicalOperations/006

Leave a Comment

Your email address will not be published. Required fields are marked *

AdsReg Magazine We would like to show you notifications for the latest news and updates. You can disable it when you want.
Dismiss
Allow Notifications