Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re: Indirect addressing problem

by sundialsvc4 (Abbot)
on Aug 28, 2015 at 14:19 UTC ( [id://1140338]=note: print w/replies, xml ) Need Help??


in reply to Indirect addressing problem

Please code “this kind of thing,” instead of “elegantly.”   Please.

Why?   Because, at a glance, I can see and understand what the first example is doing, and, even there comes a time where one of the many cases is slightly different, I can still easily maintain it and be entirely certain that the changed code still works.   In your “elegant” example, every single one of these cases has been coupled to one another.   It is no longer possible to see “at a glance” what the code is intended to do, nor to be certain that in all cases it actually does it.

Generally speaking, don’t try to economize on source-code statements, especially not at the expense of expressiveness and maintainability as has been done here.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others imbibing at the Monastery: (6)
As of 2024-03-28 19:10 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found