Algorithm visualization in js.