Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
JavaScript - For...Of Statement Example
#1
Code:
const arr = [3, 5, 7];
arr.foo = "hello";

for(const i in arr)
  {
    document.write(i + "<br>");
  }

for(const i of arr)
  {
    document.write(i + "<br>");
  }
Also follow me on Youtube for videos about video games:
https://www.youtube.com/channel/UCxfkGVU...2mQ/videos
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  JavaScript - Continue Statement Example Qomplainerz 0 321 04-04-2023, 07:49 AM
Last Post: Qomplainerz

Forum Jump:


Users browsing this thread: 1 Guest(s)