Variables are like place holders, they just hold the place of something else.
To initialize a variable, you must start off by typing
"var" followed by the name of your new variable. ("var x")
After that, type an equal sign ("=") and what the variable will be followed by a ";".
The "=" is an assignment operator.
Code is case sensitive. Variables must start with a letter or underscore.
There are different types of variables: numbers, text (strings), bool, null.
numbers: any number, javascript can handle. (decimals, negatives)
Text in coding, is called "strings." To set a variable equal to a string, type the text you want inside of quotation marks. (var x = "this is the text";) If you forget the quotation marks, javascript will think you are setting the new variable equal to another variable. To type quotes inside of the string, type "\" before each quotation mark (it is an escape character?
A Boolean variable is either true or false.
A null is nothing. When you set a variable to null, it literally equals nothing, has no value at all.