📌  相关文章
📜  javascript循环数组检查数字是否为偶数 - Javascript代码示例

📅  最后修改于: 2022-03-11 15:04:32.849000             🧑  作者: Mango

代码示例2
let getEvenNumbers = () => {
    let arr = [4,5,7,8,14,45,76];
        
    let the_evens = arr.filter(number => number % 2 == 0);
    document.write('Even Numbers: ' + the_evens);
}
    
getEvenNumbers();