var declares a variable with function scope.
Scope of var
- Global scope normally
- Start to end of the function inside of the function
- Yes, can redeclare it in the same scope
- Hosted at the top of the global scope
- It can be used before the declaration
Leave a Comment
All fields are required. Your email address will not be published.