Skip to content

Instantly share code, notes, and snippets.

@doritostains
Last active February 21, 2019 01:32
Show Gist options
  • Save doritostains/3bd03e9d3bd96c6ae08f44cbc5d9ecbe to your computer and use it in GitHub Desktop.
Save doritostains/3bd03e9d3bd96c6ae08f44cbc5d9ecbe to your computer and use it in GitHub Desktop.
// 1. Given an array of five integers in ascending order,
// write a function called “transform” that takes the array,
// multiplies each integer by 10, and produces a new array
// of strings in descending order.
let items = [1, 2, 3, 4, 5];
// Output
console.log(transform(items));
=> ['50', '40', '30', '20', '10']
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment