Closed ghost closed 6 years ago
http://eloquentjavascript.net/3rd_edition/05_higher_order.html#c_p03rPqGmn9 Anonymous arrow function doesn't use parameter i from repeat function. let message = "Wow"; repeat(5, i => { message += "!"; }); console.log(message); // → Wow!!!!! Maybe it would be more clearer repeat(5, () => { ?
i
let message = "Wow"; repeat(5, i => { message += "!"; }); console.log(message); // → Wow!!!!!
repeat(5, () => {
Thank you. I very much appreciate all your efforts.
See my comment on #328
http://eloquentjavascript.net/3rd_edition/05_higher_order.html#c_p03rPqGmn9 Anonymous arrow function doesn't use parameter
i
from repeat function.let message = "Wow"; repeat(5, i => { message += "!"; }); console.log(message); // → Wow!!!!!
Maybe it would be more clearerrepeat(5, () => {
?Thank you. I very much appreciate all your efforts.