Data Types
var num = 8; // number
var strg = "Joe"; // string
var vobj = {first: "John", last:"Doe"}; // object
var booli = false; // boolean
var arr = ["HTML","CSS","JS"]; // array
var a; typeof a; // undefined
var a = null; // value null
const pi = 3.14;
Strings
Operators
+ Addition
- Subtraction
* Multiplication
/ Division
(...) Grouping operator, operations within brackets are executed earlier than those outside
% Modulus (remainder )
++ Increment numbers
-- Decrement numbers
== Equal to
=== Equal value and equal type
!= Not equal
!== Not equal value or not equal type
> Greater than
< Less than
>= Greater than or equal to
<= Less than or equal to
? Ternary operator
&& Logical and
|| Logical or
! Logical not
& AND statement
| OR statement
~ NOT
^ XOR
<< Left shift
>> Right shift
>>> Zero fill right shift