3 ms·
That's Whitney's style. My preferred example is http://www.kparc.com/b/b.c http://www.kparc.com/b/b.c It looks obfuscated, but in fact it is just a lot of info
by yiyus 8y ago
That's Whitney's style. My preferred example is http://www.kparc.com/b/b.c http://www.kparc.com/b/b.c
It looks obfuscated, but in fact it is just a lot of information. Many people would claim dividing it in 10 files with longer function names and less tricks would make it easier to understand, but after spending a long time studying (and partly rewriting) this code, I actually find the terse version better.
- deleted 8y ago[deleted]
- taneq 8y agoThe problem with satire is that no matter how far over the line you think you've gone, someone will always wonder whether you really meant that.
- pavel_lishin 8y ago> after spending a long time studying (and partly rewriting) this code, I actually find the terse version better. I'm sure Mr. Goldberg understood his machines just fine, too.
- jungler 8y agoI've tried Whitney's style and got some good takeaways from it. I don't need that level of density, but it made me realize that when the code is already doing something very abstracted from business logic, there is no sense in trying to name the variables with more than one or two letters. (x0 and x1, appearing in geometric functions, are favorites of mine.) I also started using "result" after seeing it in Pascal code and have quite liked it for many years, but I just had the epiphany that "ans" (answer, as seen on several graphing calculator lines) would be a little more dense. Basically, it was well worth it to try these radical styles out. They did a lot to smooth my everyday coding.