Undefined Vs Null

In JavaScript, both undefined and null come under primitive data types. But they are not as simple as a string, number, and boolean. A variable is said to be undefined when it has been declared (for future use) but has no value assigned to it. For example, Line 2 prints undefined in double quotes, i.e.

Read More