✅ – BIOLOGY SCIENCE – 06-59 Aug 7

console.time('time');

['', '', '', '', ''].forEach(functionToDoStuff);

console.timeEnd('time');
console.time('time');

['', '', '', '', ''].forEach(functionToDoStuff);

console.timeEnd('time');
just want to check one thing the timeEnd function will run only after the forEach is completed. am i right ?
UU
Unknown User619d ago
R
RelativPerspektiv619d ago
wdym ?
UU
Unknown User619d ago
R
RelativPerspektiv619d ago
yes i did get the time but im not sure that the time which i got was returned after that whole loop was completed or not thats my doubt
UU
Unknown User619d ago
R
RelativPerspektiv619d ago
ok lemme do that now
R
RelativPerspektiv619d ago
i get a output like this
R
RelativPerspektiv619d ago
so that means the time end is returned after the whole loop is done right ?
UU
Unknown User619d ago
R
RelativPerspektiv619d ago
ok cool, thank you
UU
Unknown User619d ago
R
RelativPerspektiv619d ago
yep
UU
Unknown User618d ago