Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

Re: Subroutining for readability...

by andye (Curate)
on Nov 09, 2001 at 16:15 UTC ( [id://124336]=note: print w/replies, xml ) Need Help??


in reply to Subroutining for readability...

I'd go for the second option every time. Helps me not primarily with readability, but with think-ability (always at a premium, I find) and debugging.
do_stuff_hide_the_details(); do_other_unrelated_stuff(); sub do_stuff_hide_the_details { do_specific_thing(@these_params); do_specific_thing(@those_params); } sub do_specific_thing { #fiddle about with details }
iyswim! ;)

cheers,
andy.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others sharing their wisdom with the Monastery: (4)
As of 2024-04-25 10:28 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found