This WASM version is based on my native code implementation which implements something like this.
I believe I independently discovered this concept of a tetromino bag. I've been calling it "Gambler's Accurate Model of Reality" in a homage to Gambler's Fallacy.
I believe I independently discovered this concept of a tetromino bag. I've been calling it "Gambler's Accurate Model of Reality" in a homage to Gambler's Fallacy.
https://github.com/raulgrell/tetris/commit/4305cd1ac1bcc9443...
That commit is from Feb 7, 2016, and you can see all the TODO comments for the zig features that didn't exist yet :-)