Quantcast
Channel: สอน PHP สอนทำเว็บด้วย Joomla ระบบ CRM บทความ Hosting - สอน PHP สอนทำเว็บด้วย Joomla ระบบ CRM บทความ Hosting
Viewing all articles
Browse latest Browse all 24

Chapter 10 - JavaScript Operators

$
0
0

Operator is marked with a number in action, which is divided into two or more. Such as operator assistance in mathematics, logic, comparison, and so on. 

Operator for calculating Arithmetic Operators. 

Operator router that will be used to calculate mathematical form. 

JavaScript Arithmetic Operators

Operator                 Description
+                     Addition
- Subtraction
* Multiplication
/ Division
% Modulus (division remainder)
++ Increment
-- Decrement

 

 JavaScript Assignment Operators

Assignment operators are used to assign values to JavaScript variables.

Given that x=10 and y=5, the table below explains the assignment operators:

Operator         Example            Same As        Result
= x=y              x=5
+= x+=y    x=x+y      x=15
-= x-=y  x=x-y     x=5
*= x*=y                x=x*y       x=50
/= x/=y                x=x/y       x=2
%=          x%=y               x=x%y     x=0

 

 

Next

{--mlinkarticle=2950--}Chapter 11 - JavaScript Comparison and Logical Operators{--mlinkarticle--}


Viewing all articles
Browse latest Browse all 24

Trending Articles