Why does it log this output to the console?
It needs to be
As its a function
I get it oops ha. I could also put console.log(plantNeedsWater(“Wednesday”)); to override the Tuesday value.
Are functions types of methods?
no? Those are two separate function calls, one doesn’t override the other. But you do not log the returned result of the first function call, thus nothing is shown in the console
.log() is a method of the
console object for example. while plantNeedsWater is a function
oh I get it; that’s why functions are so useful, they can be called multiple times.
Thanks so much for your help!