using for each method javascript code example
Example: foreach jas
const array1 = ['a', 'b', 'c'];
array1.forEach(element => console.log(element));
const array1 = ['a', 'b', 'c'];
array1.forEach(element => console.log(element));