pattern-match-2d.js demo, inspired by MarkovJunior by Maxim Gumin.