There are rules and conventions in naming variables in any programming
language. It is good practice to use descriptive names for variables.
* You can't use space to separate characters.
userName not user Name
*Capitalize the first letter of every word except the first
salesTax or userFirstName
To assign values to variables, add an equal sign and the value:
var userName = "Smith"
var price = 100
Declare & Assign values to variables in JavaScript
Reviewed by Viththiyakaran
on
9:57 PM
Rating:
No comments: