Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re: Should I leave behind beautiful code or readable code?

by jwkrahn (Monsignor)
on Mar 28, 2007 at 09:02 UTC ( #606948=note: print w/ replies, xml ) Need Help??


in reply to Should I leave behind beautiful code or readable code?

I have two questions that would concern me as a maintainer:

1.   When you use split(/ /) are you saying that you know that the data will always be separated by exactly one space character or did you really mean to use split(/ +/) or split(/\s+/) or preferably split(' ') instead?

2.   Why are you using map twice when you only need to use it once?   For example:

return map split( / /, uc, 2 ), @somearray;


Comment on Re: Should I leave behind beautiful code or readable code?
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (7)
As of 2015-07-05 12:56 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (66 votes), past polls