Answers for "javascript find odd numbers in a range"

0

javascript find all odd between two numbers

function oddNumbers(l, r) {
    let arr = [];
    while (l <= r) {
        arr.push(l);
        l += 1;
    };
    return arr.filter(n => n % 2);
}
Posted by: Guest on January-04-2021

Code answers related to "javascript find odd numbers in a range"

Code answers related to "Javascript"

Browse Popular Code Answers by Language