3 ms·
Can anyone explain what is going on here?
by JacksonGariety 13y ago
Can anyone explain what is going on here?
- gry 13y ago> Once upon a midnight dreary, while I {pon}ered It's a visual demonstration how gzip works. The first line says it all. 'pon' matches the bytes in 'upon', the first first instance, thus it's pointer to those bytes instead of "duplicating" the pattern. As the text goes on, there are more matches, thus more pointers.
- jws 13y agogzip works by constructing, on the fly, a dictionary of strings it has seen before and sort of inserting them by reference. When you see something red and in braces, that is a bit that has occurred before and been inserted by reference. I'm guessing that it is happening at a constant symbol rate, you'll notice it speeding up as it includes more and more text by reference instead of a single character at a time.
- promoCode 13y agoFor those who don't feel like watching a youtube video that shows a recording of the animated command line output, simply click this link: https://rawgithub.com/jvns/7155528/raw/ef9785f023fc68d78dc4f61e732007149eec1e69/raven.html https://rawgithub.com/jvns/7155528/raw/ef9785f023fc68d78dc4f... The author explains what he did to produce this output, and provides links to his program's source code in his post, so OP's link is still a worthwhile read, but that link cuts to the chase.