What will the final count log show in Javascript? And why? Go!

Estimated read time 1 min read

Post Contenthttps://www.youtube.com/shorts/kXIgLG9INQU

​ A quick JavaScript brain teaser. We start with an array created using new Array(3). Then we run a small piece of code that looks completely reasonable. At the end, we log a value, which may not be what you expected. What number appears, and why? Watch the video and share your answer in the comments.

Subscribe to Google for Developers → https://goo.gle/developers

Speaker: Sayali Godbole   Read More Google for Developers 

You May Also Like

More From Author