The most viewed items
const tnwAges = [19, 39, 28, 43, 29, 45, 53];
function tnwFun1(){
document.getElementById("demo").innerHTML = tnwAges.join("
");
}
function tnwFun2(){
document.getElementById("demo").innerHTML = tnwAges.findIndex(chkAge);
}
function chkAge(age){
return age > document.getElementById("myAge").value;
}
No comment to show.