Please login to start chat

ICT Solutions 11 Jun 2022, 09:58:18
Category : JavaScript Tutorials

forEach (JavaScript Array Method)

const student = ["Aung Aung", "Maung", "Kyaw", "Zaw", "Soe", "Moe"];
let names = "";
function tnwFun1(){
student.forEach(tnwFun2);
}

function tnwFun2(item, index){
names += index + " : " + item + "
";
document.getElementById("demo").innerHTML = names;
}

Comments:

No comment to show.

Available Services
Download Android Application