Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: Syntax explanation required

by sundialsvc4 (Abbot)
on Jan 02, 2013 at 21:29 UTC ( #1011354=note: print w/ replies, xml ) Need Help??


in reply to Syntax explanation required

And I would cordially augment Anathasius’s excellent response by making two observations:

  1. There’s More Than One Way To Do/Say It (TMTOWTDI™) ... and ...
  2. “At the end of the day,” the hands-down winner is:   the one that is the most clear, to the greatest number of human beings who will actually encounter it, either now or in the distant future.

When you are writing source code, it frankly does not matter whether what you have written is “efficient,” much less “clever.”   (And in making that comment, I consciously and respectfully intend to steer the middle-ground against acknowledged valid ... [BrowserUK] ... edge-case exceptions ...)   What (typically) matters is that what you’ve written is drop-dead obvious ... and maintainable.   (You are not at the computational bleeding-edge and never will be.)   Even if the piece of source-code that you encountered works perfectly as-writ (as I presume it does), it triggered a show-stopper question from you that was sufficient to prompt a humble-petition to The Monks.   For that reason alone, it should be judged Insufficient.   It should, at the very least, be prefaced by a comment.

Yeah, there is a “hard dollars” motivation for doing that.   The mere fact that it triggered a public comment titled “Syntax explanation required” classifies it as “very $$costly$$.”   Most of the time, there are many equally-valid ways to express your intentions to the digital computer, and so what really matters is how clear it is to your colleagues.


Comment on Re: Syntax explanation required
Re^2: Syntax explanation required
by Anonymous Monk on Jan 02, 2013 at 21:44 UTC
    What?

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1011354]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (6)
As of 2014-10-26 07:56 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    For retirement, I am banking on:










    Results (152 votes), past polls