Putting it all together

Practice your knowledge by solving these challenges. Learn how to manipulate arrays and objects to work with data and create useful functions.

INSTRUCTIONS

Modify this function to take in an array as an argument. Return a new array that is identical to the original array, except that each item is multiplied by 2.

Example:

double([1, 2, 3]); // -> [2, 4, 6]

Create a free account to access the full course.

By signing up, you agree to Educative's Terms of Service and Privacy Policy