Tagged: JavaScript

Not a Number in JavaScript

Not a Number in JavaScript

What is a Not a Number In my last post I was talking on how to use numbers in JavaScript. Now I want to talk about the notorious Not a Number invalid value. Also know as NaN. A Not a Number indicates that the value of a variable or the...

Numbers in Javascript

How to deal with numbers in JavaScript

We can deal with numbers in JavaScript in many ways. Lets look at the basics. The size of a JavaScript number In JavaScript a number is always a 64 bit floating point. There is no integer, nor decimal, nor bit. Only a 64 bit floating point. This precision follows the international...

Dating in JavaScript

Since we are in Saint Valentine’s day, I was thinking about dating… Not about dating someone, but how to have a date in JavaScript. There are 4 ways to create a date in JavaScript by using the Date data type: Date() Date(number) Date(number1, number2, number3, number4, number5, number6, number7) Date(string)...

Objects in JavaScript? 3 ways to do it.

JavaScript is not an OOP language.  This is one of the challenges faced by server-side programmers, specially if you use OOP languages likes C, C++, C# or Java.  We know that using objects give us clarity and a way to translate the problems we are trying to resolve through code....