3 ms·
What's the point of minifying code that is anyways going to be compiled?
by paxys 2y ago
What's the point of minifying code that is anyways going to be compiled?
- byzantinegene 2y agoI'm assuming 3000 bytes refers to the uncompiled minified code
- exac 2y agoIndeed, and the question is why do that? We can count LOCs just fine already.
- thrw42A8N 2y agoBecause it'd be very hard to compare short program length otherwise? 5 LoC says nothing.
- ffsm8 2y agoTechnically, it depends on the language. I.e. python doesn't have anything like a semicolon to combine multiple statements and assignments per line But yeah, for C the LOC metric can be gamed to a silly degree
- mattashii 2y ago> python doesn't have anything like a semicolon to combine multiple statements Python does have a "semicolon to combine multiple statements", and has further (lambda f: f(f)) expressions for complex expressions with local names and scopes. (not that using either for those would result in pythonic code, but it is certainly not missing from the language)
- ffsm8 2y agoOh, you're right. I should've tested that before writing my comment. Thanks for calling me out
- stavros 2y agoYeah but lines in anything should be "lines formatted with a standard formatter", not just "one line with ten thousand semicolons in it".
- oneeyedpigeon 2y agoYou also need to define whether the code has to be raw CPU instructions or if it's allowed to use an external library containing all the code humanity has ever produced.
- thrw42A8N 2y agoThe usual with this is "whatever ships with the language compiler and OS".
- CaptainNegative 2y agoWhat counts as a standard formatter? Python one-liners are Turing complete even without semicolons, evals, execs, and with finite stack depth. E.g. some formatters keep this at one line, while others introduce line breaks https://yonatan.us/misc/bf.html https://yonatan.us/misc/bf.html .
- heinrichhartman 2y agoWhat's the point of art?
- InsideOutSanta 2y agoTo complain about it not having any point on Hacker News, thus creating a paradox where the complaint itself becomes the most discussed and engaging aspect of the post.
- actionfromafar 2y agoThis is not what HN is for and your comment has no point. (Upvoted.)
- hk__2 2y agoThat’s craftmanship, not art.
- lores 2y agoA talk by Brian Eno convinced me that there is no meaningful difference between the two, and I've yet to see a definition of art that does not end up in self-contradiction if we try to make the distinction.
- vouaobrasil 2y agoThe point of art is the expression of human experience and ability, but it frequently becomes perverted into serving capitalist tendencies. So: 1. Art becomes content 2. Automation to make life better becomes automation for profit 3. Life becomes meaningless achievement At some point, there is always the counterpoint of balance and we don't have that.
- paxys 2y agoSo a standard C program is not art, but if you remove newlines and shorten variable names it suddenly becomes art?
- 2y ago
- kgwgk 2y agoPeople ask me, 'What is the use of climbing Mount Everest?' and my answer must at once be, 'It is of no use.' There is not the slightest prospect of any gain whatsoever. Oh, we may learn a little about the behavior of the human body at high altitudes, and possibly medical men may turn our observation to some account for the purposes of aviation. But otherwise nothing will come of it. We shall not bring back a single bit of gold or silver, not a gem, nor any coal or iron. If you cannot understand that there is something in man which responds to the challenge of this mountain and goes out to meet it, that the struggle is the struggle of life itself upward and forever upward, then you won't see why we go. What we get from this adventure is just sheer joy. And joy is, after all, the end of life. We do not live to eat and make money. We eat and make money to be able to live. That is what life means and what life is for. -- George Mallory
- lucianbr 2y agoIs it carefully minified by hand, or by another program? Because I really, really don't see how calling a minifier is "the struggle of life itself upward".
- vouaobrasil 2y agoI agree with Mallory that we make money to live but I also think that modern technological society has turned pursuits into highly specialized perversions that aren't even inspiring any more. The worldwide coverage of mountain climbing has even turned mountain climbing into a somewhat arbitrary thing in terms of "climbing everests": first it was to the top of the mountain (cool), then it was to the top in a certain time, then it was without supplementary oxygen, then it was climbing all 8,000m+ mountains, then it was doing THAT without oxygen... At some point it's diminishing returns and becomes stupid -- and results in people just killing themselves, and AI is already on that level. With every achievement there also comes a responsibility and our society is just achievement without responsibility.
- stavros 2y agoI think you missed the point of the quote entirely. When I do something, I don't do it because nobody has ever done it before. I do it to see if _I_ could do it. Otherwise nobody would ever run a marathon again.
- deleted 2y ago[deleted]