Should you write your functions like this:
int foo()
{
if (bar)
return 1;
return 2;
}
Or like this?
int foo()
{
if (bar)
return 1;
else
return 2;
}
Is one way objectively better than the other, or is it a matter of personal preference? If one way is better, why?