- A forEach() method is used when wanting to call a function on each element in an array.
A map() method is also used to call a function on each element in an array BUT map saves the return values of those functions and returns a new array of the same size.
-
Function - is a block of code that executes something
Method - is a block of code that executes something but is associated with an object
-
Closure - A collection of all the variables at the time of the creation of a function.
-
Four rules of precedence in the 'this' keyword
- Default Binding
- Implicit Binding
- Explicit Binding
- New Binding
-
The 'super' keyword is used to called functions on the parent object.