The most viewed items
const tnwAges = [25, 18, 29, 20, 40, 32, 53, 24];
function tnwFun1(){
document.getElementById("demo").innerHTML = tnwAges.join("
");
}
function tnwFun2(){
const result = tnwAges.filter(chkAge);
document.getElementById("demo").innerHTML = result.join("
");
}
function chkAge(age){
return age > 20;
}
No comment to show.