Tag Archives: Javascript

JavaScript Strict Mode

Using the “use strict” statement we can activate the strict mode for our JavaScript code. JavaScript Strict Mode Overview The Strict Mode introduced in JavaScript ECMAScript version 5. And we can activate it for our script using the “use strict” statement. Unlike other JavaScript code it is not a general statement, but a literal expression that eliminates some… Read More »

JavaScript Bitwise Operations

JavaScript support 7 bitwise operators that perform bits operation between two binary values using 32 bits. Although JavaScript store all the numbers as 64 bits floating points, but when its comes to bitwise operation it treats the 64 bits numbers as 32 bits binary numbers. This means before the bitwise operation performs on the numbers the JavaScript engine… Read More »

JavaScript Booleans

In JavaScript, there are two values that represent Boolean Data type true and false. Boolean Values Often in programming, we come across the situation where we want a data type that can evaluate results in the following formats. Yes or No On or Off True or False In such situations, we can use a Boolean data type, that… Read More »

JavaScript Random

In the previous tutorial, we learned about JavaScript Math objects, there we also learned about random() method that can generate random numbers. In this tutorial, we will discuss the Math random method in detail because it is one of the most important and widely used JS Math methods. Math.random() The Math.random() method can generate a random number between… Read More »