4 ms·
One of the commenters says " The answer is probably just situational, but I'd bet that elegance is unimportant for a lot of code." IMO that is miles from the t
by gldalmaso 15y ago
One of the commenters says " The answer is probably just situational, but I'd bet that elegance is unimportant for a lot of code."
IMO that is miles from the truth. I handle code that "just gets things done" everyday and it is a real pain. Elegant code is not code that is just well formatted and clean, is code that solves a problem in an elegant way, a way that will scale better and that is easy to understand and maintain.
The real problem is that it's really really hard to get managers and clients to understand to value of elegant code.
When hell that is left after code-like-hell to get things done gets in the way of maintaining the code, the blame gets thrown in the programmer that didn't write good code. But they never want to trade off time for quality. And when we ask for time to get things done with quality, they assume it's an ego thing...
- JoeAltmaier 15y agoAgreed. Elegant code is thin, tall and streamlined. Half as many lines as a quick-and-dirty wad. If you have half as many lines of code, -- it takes half as long to read it -- it may be twice as easy to explain -- you may be able to fit it all into your brain at once -- it compiles faster -- it may run faster Remember the slowest processor on the planet is your wetware. That's the place where space and speed are critical factors.