“That response does not work.”
I didn’t say (or mean, or imply) “you don’t know that?” and I’m helping you for free out of the kindness of my heart. Keep that in mind.
What I’m trying to do is help you think through things and come to some realizations yourself because science says we learn and remember better when we’re forced to recall and work things out rather than handed answers on a silver platter. If I don’t hand you an answer on a silver platter, try rereading the text, or doing some independent research.
I’m pushing you to work independently on purpose because that’s what good teachers do. They challenge you to work harder. You’ll learn it better that way.
Recall that the article you replied to demonstrated method syntax:
const arr = [1, 2, 3];
arr.map(double); // [2, 4, 6]
A method is a function associated with an object. In this case, the object is the
arr array. Notice that the dot notation is used to access the
.map() method on the
In the hypothetical example:
inc . double (2)
double property on that object, but
inc does not have a
The result would be the error:
inc.double is not a function