Skip to content

Instantly share code, notes, and snippets.

@dance2die
Created April 21, 2018 21:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dance2die/042c3f009b4836d3673fe385f0976321 to your computer and use it in GitHub Desktop.
Save dance2die/042c3f009b4836d3673fe385f0976321 to your computer and use it in GitHub Desktop.
function rangeDemo() {
const oneToTen = Array(10)
.fill()
.map((_, i) => i + 1);
WriteLine(`One to Ten => ${oneToTen.join(",")}`);
const randomRange = Array(3)
.fill()
.map((_, i) => i + 999);
WriteLine(`Three numbers from 999 => ${randomRange.join(",")}`);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment