Duvvuru Kishore’s Post

#javascript #mcqs-R Preparing for a JavaScript interview? Enhance your knowledge and test your skills with JavaScript multiple-choice questions! 💡 Whether you're a beginner or a seasoned developer, these questions will help you brush up on important concepts and get ready for your next interview. Check them out below . For all the interview question - Follow Duvvuru Kishore for more interview questions and mcq's #frontend #JavaScript #interview R- Repeat

  • graphical user interface, application

A) 3 3 3 → var is function-scoped, so all timeouts share the same i, which becomes 3 after the loop ends. B) 0 1 2 → let is block-scoped, so each iteration gets its own i value.

A) 3 3 3 B) 0 1 2 The real lesson here isn’t setTimeout, it’s scope + closures. var shares one function-scoped binding. let creates a new block-scoped binding per iteration. Small keyword. Big production difference

Option A) is correct

Like
Reply
See more comments

To view or add a comment, sign in

Explore content categories