Skip to content

Instantly share code, notes, and snippets.

@KJLJon
KJLJon / Deck.js
Created April 28, 2018 04:09
Xincrol algorithm example
import Xincrol from './Xincrol';
class Deck {
constructor(...rules) {
this.setRules(rules);
this.size = rules.reduce((a, b) => {
const base = typeof a === 'string' ? a.length : a;
return base * b.length;
});
this.shuffle();

Keybase proof

I hereby claim:

  • I am kjljon on github.
  • I am kjljon (https://keybase.io/kjljon) on keybase.
  • I have a public key ASDTlC8J6Xa9dsSFEWw4so4T6OxVWRsDOUH7WLxYZmz6yAo

To claim this, I am signing this object: