Skip to content

Instantly share code, notes, and snippets.

@alion02

alion02/good.js Secret

Created September 20, 2018 09:46
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 alion02/d8f89857d82d0f9e7d68df8d808fad63 to your computer and use it in GitHub Desktop.
Save alion02/d8f89857d82d0f9e7d68df8d808fad63 to your computer and use it in GitHub Desktop.
// Setup
class SomeClass {
constructor(thing) {
this.thing = thing;
}
}
// Persistent storage
let turnsPassed = 0;
// Naming your own variables
return (me, opp) => {
++turnsPassed;
return opp.dead ? "m" : "n";
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment