JavaScript is an open and cross-platform scripting or programming language that allows you to implement complex features on web pages. JavaScript is easy to implement because it is combined with HTML.

Number

Example:

JavaScript Number

String

Example:

JavaScript String

Variable

Example:

JavaScript Variable

Conditional Statement

Conditional Statement

Operators

Example:

Assign values to variables and add them together

Objects

Example:

JavaScript object

Function

Example:

JavaScript Function

Arrays

Example:

JavaScript Array

Some important methods of array are:

pop() method removes the last element from an array.

push() method adds a new element to an array (at the end).

shift() method removes the first array element.

unshift() method adds a new element to an array (at the beginning).

splice() method can be used to add new items to an array.

slice() method slices out a piece of an array into a new array.

Math

Some important methods of math are:

math.round() method returns the nearest integer number.

math.sqrt() method returns the square root of a number.

math.ceil() method returns rounded up to its nearest integer.

math.floor() method returns rounded down to its nearest integer.

math.random() method returns a random number.

Null & Undefined

Front End Developer | MERN Stack Developer | JavaScript & React Enthusiast | Network Engineer