Skip to content

Instantly share code, notes, and snippets.

@EvanHsieh0415
Last active November 21, 2023 14:06
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save EvanHsieh0415/6f8c86608947e728e651fa162519c413 to your computer and use it in GitHub Desktop.
Save EvanHsieh0415/6f8c86608947e728e651fa162519c413 to your computer and use it in GitHub Desktop.
const range = len => Array.from({ length: len }, (_, i) => i + 1)
const len = array => array.length
const map = Array.prototype.map
const filter = Array.prototype.filter
const reduce = Array.prototype.reduce
String.prototype.join = function(array) { return array.join(this) }
Object.prototype.items = function() { return Object.entries(this) }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment