Primitives Flashcards
1
Q
variable can change type!
A
let nums = 12;
nums = false;
nums = 1234;
it may not be a very good idea
2
Q
string quotes
A
can be single or double, you can even use double inside single or vice versa
‘he said, “haha” ‘
“he said, ‘haha’ “
good practice to be consistent about the choice inside a project
3
Q
type of var operator
A
typeof 87 //”number”