Data Types in JavaScript


JavaScript data types

Data type conversion

stringvar = "these are 10 strings";
numvar = parseInt (stringvar);

//numvar would contain the value 10

Storing user data in variables

firstName = prompt ("First Name : ");
lastName = prompt ("Last Name : ");
title = prompt ("Title : ");