JavaScript String

JavaScript String is a series of zero or more characters, represented by using single or double-quotes. There are two ways to create a string: Escape Sequence As strings are written in double or single quotes so if there is a need to show your strings in double/single quotes as output use backslash \’ \” with … Read more

JavaScript Data Types

JavaScript Data types have an important concept in JavaScript. It contains various data types such as numbers, objects, strings, and more. Java Script executes expressions from left to right different sequences will give different results. JavaScript Types are dynamics means that we can use the same variable to execute the different data types: JavaScript Data … Read more

JavaScript Assignment

The JavaScript assignment operators are used to assign the right-side operand values to variables. The = sign is used for assigning a value to a variable. For example, we can perform the increment using the JavaScript assignment operator in the following way: JavaScript Assignment – Operators Following are some assignment operators used in JavaScript: Operator … Read more

JavaScript Arithmetic

JavaScript arithmetic operators are used to perform arithmetic operations on numbers (like variables or literals). An arithmetic operation is performed on 2 numbers typically. These numbers are known as an operand and the operation is done by an operator. Following are some basic JavaScript arithmetic operators: Operator Description + Addition – Subtraction * Multiplication ** … Read more

JavaScript Operators

JavaScript Operators are special symbols used to perform operations on operands (values and variables). JavaScript operators include operators as in other languages. For example, 1 * 2, where * sign is an operator and 1 is left operand and 2 is a right operand. + operator adds two numeric values and produces a result which … Read more

JavaScript Reserved Words

JavaScript Reserved words have special meaning and can not be used in your code as variables, function names, or loop labels. It is important to note that JavaScript is a case-sensitive language (whereas HTML is not case-sensitive). JavaScript Reserved words Here is a list of JavaScript reserved words (and words to avoid) in JavaScript: abstract … Read more

JavaScript Const

The JavaScript const variable is also used to declare a variable like var. But we cannot redeclare const in the whole program. The const keyword was introduced in ES6. The JavaScript const variables should be assigned the value at the time of declaration. The JavaScript const should be used when we declare There is a … Read more

JavaScript Let

The let keyword is used for variables declaration in JavaScript with block scope. The variables defined with JavaScript let word cannot be redeclared. We accidentally cannot do this. The syntax for the let keyword is given below: JavaScript Let – Global Scope The variables that we declared in the main body or outside the function … Read more

JavaScript Variables

JavaScript variables include variables that hold the data value and can be changed anytime. If we didn’t have JavaScript variables available, we’d have to implement a giant code block that checked what the entered name was, and then display the appropriate message for any name. This is obviously really inefficient (the code is a lot bigger, … Read more

JavaScript Comments

JavaScript comments are used to deliver messages. It is used to add information about the code, warnings, or suggestions so that end-user can easily interpret the code. Comments are annotations in the source code of a program that are ignored by the interpreter, and therefore have no effect on the actual output of the code. Comments … Read more