learning javascript
difference between let vs var vs const
- const is static value and cant be changed. global scope
- var is scoped to the immediate body
var does hoisting, which is automatically putting the declaration of the variable on top of the file (first line). - let are scoped to the immediate enclosing