Answers for "JS iterate over an array"

0

JS iterate over an array

const beatles = [ "john", "paul", "ringo", "george"];

beatles.forEach((beatle) => {
  console.log(beatle);
});
Posted by: Guest on September-15-2021
0

JS iterate over an array

const beatles = ["paul", "john", "ringo", "george"];

beatles.forEach((beatle) => {
  console.log(beatle.toUpperCase());
});
Posted by: Guest on September-15-2021

Code answers related to "Javascript"

Browse Popular Code Answers by Language