Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask

Re: Re: (crazyinsomniac) Re: Coding superstitions

by seattlejohn (Deacon)
on Jan 15, 2002 at 12:24 UTC ( #138847=note: print w/ replies, xml ) Need Help??

in reply to Re: (crazyinsomniac) Re: Coding superstitions
in thread Coding superstitions

FWIW, I prefer your version, simply because my brain effortlessly translates the else into $_[0] != 'ooyah', so it is immediately clear to me that the block gets executed if and only if $_[0] != 'ooyah'. I think I can understand the prof's desire for the "dangling return", but I also think it would require a few more clock cycles for my brain to look at that and be convinced exactly under which conditions 0 would be returned. (At the very least, I'd have to see the return 1 above to know that the return 0 would never get executed if the if was true -- because the if might just have done some work without actually returning...)

Comment on Re: Re: (crazyinsomniac) Re: Coding superstitions
Select or Download Code

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (5)
As of 2015-11-25 05:27 GMT
Find Nodes?
    Voting Booth?

    What would be the most significant thing to happen if a rope (or wire) tied the Earth and the Moon together?

    Results (671 votes), past polls