Find the console output:let i;for (i = 0; i < 3; i++){const log = () =>{console.log(i);}setTimeout(log, 100); } a. 333 b. 345 c. 444 d. 3456 code example
Example: for (var i = 0; i < 10; i++) { setTimeout(function () { console.log(i) }, 10) } What
for (var i = 0; i < 10; i++) {
setTimeout(
(function (i) {
console.log(i)
})(i),
10
)
}