find odd number between 1 and 5 javascript code example
Example: 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);
}