Category JavaScript

Conditional Statements in JavaScript

Types of Conditional control flow statements in JavaScript

A simple JavaScript program consists of a set of statements that generally contain expressions and end with a semicolon. When we execute a JavaScript program, at a time, only one statement executes by JavaScript interpreter. These statements are called sequential…

Operator Precedence in JavaScript

When we work with a complex expression that contains more than one operator, it is vital to know the order in which JavaScript uses rules of operator precedence to calculate the value. The precedence of operators in JavaScript helps to…

TypeOf Operator in JavaScript

The “typeof” operator in JavaScript is a unary operator that checks data types of its operands. The operand can be either literal, variable, function, or object. The typeof operator has only one operand. It returns the type of variable of…

Bitwise Operators in JavaScript

JavaScript Bitwise AND operator example

JavaScript also supports a set of bitwise operators similar to other programming languages like Java. Bitwise operators in JavaScript are those operators that works at bit level comprising ones and zeros (i.e., binary representation) rather than decimals or hexadecimals. Here,…