JavaScript has the following types:
A number starting with 0 will be a octal notation. (digits 0-7) Example: 0754.
A number starting with 0x or 0X will be hexadecimal notation. Example: 0x7aff. (cap case can also be used).
Contains a decimal point “.” or “e”. The e or E indicates exponential notation. Example: 9.32e3.
The values are: “true” and “false”.
The following are considered false: 0, null, false, NaN, undefined, or the empty string ("").
For example: "something".
Example:
myObj = new Object();
and may others.
A special value “null”. This can be assigned to function or variable to undefine them.
When a variable has not been assigned, it is “undefined”.
Reference:
See also:
Page created: 2005-05. © 2005 by Xah Lee.