Variables Flashcards
(14 cards)
What is data?
Anything that is meaningful to the computer
Name the 7 different DATA TYPES
Undefined, null, boolean, string, symbol, number and object
Can computers perform mathematical operations on a string?
Yes!
Can computers perform mathematical operations on a number?
No!
What do variables allow computers to do?
Variables allow computers to store and manipulate data in a dynamic fashion
Which of the 7 different data types can be stored in a variable?
Any of them!
What is the means and ends of variables?
Variables are a means to have a simple same represent certain and specific data that we want to refer to
What is the difference between computer variables and mathematical variables?
Computer variables can store different values at different times!
Variables names can be made up of numbers, letter, and ‘$’ or ‘_’ but cannot contain or start with what?
Variables cannot contain spaces and start with a number!
In JavaScript, what do we use to store a value in a variable?
The “assignment” operator
Assignment always goes from “____” to “____”.
Right to left!
When JavaScript variables are declared, they have an initial value of “____”
Undefined!
If you do a mathematical operation on an ‘undefined’ variables, your result will be “___”
‘Nan’!
In JavaScript, all variables and function names are “____”“____”
Case sensitive