Menu
Coddy logo textTech

Double The Odds

Part of the Fundamentals section of Coddy's JavaScript journey — lesson 76 of 77.

challenge icon

Challenge

Easy

Write a function named doubleOdds that takes one input:

  1. numbers - an array of numbers.

The function should:

  1. Double only the odd numbers in the array.
  2. Return the resulting array.

Try it yourself

function doubleOdds(numbers) {
    // Write code here
}

All lessons in Fundamentals