What does this method's return statement return?
- by Kevin
I saw a method written in C# that returns a boolean value. The method's return statement looks like this:
return count > 0;
If I'm reading this correctly, it returns a value if count is greater than zero. What happens if the value of 'count' is not greater than 0? What gets returned? Zero? If that's the case, couldn't the return statement just say:
return count;