JavaScript is an untyped language. This means that a variable can hold any datatype. It also means that a variable may be assigned data of one particular datatype and then later be given data of a different datatype. For example:
var x = 'Joey JavaScript';
x = true;
x = 1;
In the preceding example, the variable x is initialized containing the string datatype. It is than assigned a value that results in it holding the Boolean datatype. Finally, it is assigned 1, giving it the number datatype.
Many other languages are strongly typed, which means that a variable can only be associated with the datatype to which it is declared. This makes it easier to enforce datatyping rules within programs. JavaScript is untyped, however, which makes it more difficult to enforce datatyping rules but results in simplicity in developing programs quickly.