Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

When I hear "Prolog", it reminds me of the quote about Prolog:

"The elegant solution is not efficient. The efficient solution is not elegant"



On the other hand, Richard O'Keefe claims in _The Craft of Prolog_, that "elegance is not optional":

""" Elegance is not optional.

There is no tension between writing a beautiful program and writing an efficient program. If your code is ugly, the chances are that you either don’t understand your problem or you don’t understand your programming language, and in neither case does your code stand much chance of being efficient. In order to ensure that your program is efficient, you need to know what it is doing, and if your code is ugly, you will find it hard to analyse. """

https://programmingisterrible.com/post/39499310419/elegance-...


Common nitpicking, here for fun: both sentence kind of repeat one another, as they mean nearly the same thing. They could be expressed as one more symmetrical sentence, something like: "the set of efficient solutions and the set of elegant solutions are disjoint" (they have no common element).


"Efficiency like quantity has a quality of its own"




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: