Skip to content

Instantly share code, notes, and snippets.

@dminuoso
Created November 12, 2017 23:53
Show Gist options
  • Save dminuoso/eae5ea0700cb717d092c093820c43847 to your computer and use it in GitHub Desktop.
Save dminuoso/eae5ea0700cb717d092c093820c43847 to your computer and use it in GitHub Desktop.
const idIfEq = (a, b) => a === b ? a : null
moves.find((row) => row.reduce(idIfEq))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment