Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: Control Flow - Multiple returns or nested conditionals

by jakeease (Friar)
on Oct 08, 2010 at 10:08 UTC ( [id://864175]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    double getPayAmount()
    {
    ...
    }
    return result;
    }
    
  2. or download this
    double getPayAmount()
    {
    ...
    if(m_isRetired) return retiredAmount();
    return normalPayAmount();
    }
    

Log In?
Username:
Password:

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

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

    No recent polls found