Which will be returned in a program
<p>I was wondering what will be returned in a java program when you have multiple returns in a program.</p>

<pre><code>private int numberReturner()
{
    if (a) return a;
    else if (b) return b;
    for (int i = 1; i &lt; board.size()-1; i++)
    {
        if (c) return c;
    }
    return d;
}
</code></pre>

<p>So lets say a is true, (it should return a), but wouldn't it return d because that is the final line of code in the whole program? Why is this so?</p>

<p>Sorry if I worded this a bit strangely...</p>
