Preview:
//.map takes an argument of a callback function and returns a new array

const animals = ['Hen', 'elephant', 'llama', 'leopard', 'ostrich', 'Whale', 'octopus', 'rabbit', 'lion', 'dog'];

// Create the secretMessage array below
const secretMessage = animals.map(animals =>{
return animals[0];
});

console.log(secretMessage.join(''));
//output 'HelloWorld'
const bigNumbers = [100, 200, 300, 400, 500];

// Create the smallNumbers array below
const smallNumbers = bigNumbers.map(bigNumbers =>{
  return bigNumbers / 100;
});

console.log(smallNumbers)
//output [ 1, 2, 3, 4, 5 ]
downloadDownload PNG downloadDownload JPEG downloadDownload SVG

Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!

Click to optimize width for Twitter