[…] This post was mentioned on Twitter by kicauan, hkrnws, Hacker News, Thomas Buck, Kalid Azad and others. Kalid Azad said: New Post: Brevity Is Beautiful http://bit.ly/c2Gzz1 […]
I loved this line: “Writing isn’t about words, it’s about recreating ideas”. It reminds me of the “Language” section from “Design Principles Behind Smalltalk”.
[…] Models are simplifications, we all know this: assume an intelligent reader and don’t encumber your writing to satisfy every critic. Corner cases are exactly that, and should live away from the main text. via betterexplained.com […]
Wonderful write up. I agree with every point(but to be honest I feel a bit silly now ) But still, thanks so much for the great insight. I’ll remember it whenever I write next.
@steve: I like it! Exactly, asking for a “Word count” doesn’t make sense – ask for an idea count!
@Eric: Thanks, I had considered that but I prefer the explicit “cat” since it makes it easier to insert new commands (i.e. you want mycommand before the sort, now you have to remove foo.txt and feed it to mycommand… and if mycommand doesn’t take a filename (just stdin), you need to do a cat anyway).
I haven’t come across that book, it looks interesting! Yeah, it’s neat thinking about communication one level higher than the medium itself.
Brevity, I could see in my most of my friends slang. Words like “Yo”, “Howdy”, “Wassup” for things that are used to express wishes.
This doesnt make people confused. Or people understand it clearly.
But in terms of code, not all people like brevity or not every one aware of it or not everyone accepts it ( Company’s own coding standards )
I’ve written code so concise, but still I was told to expand it.
var validName = !name.isBlank() && !name.containsSpecialChar()
@Mind: Yes, sometimes there are conflicting goals around readability and maintainability – brevity is good, but whitespace can be helpful too :). In this case, separating the conditions allows you to assign multiple related properties based on one test, or have custom logic (i.e. return early if invalid, etc.). A lot of this is a matter of design style though.
@khalid: Yes, I agree that I’m not opposing the styling concepts. But I would like to emphasize that for the sake of styling, we shouldn’t be. Coz, that piece of code sets only one property :-).