Nothing wrong with return types if he doed not need non-whole results.
Your problem is with (5/9) statement. C++ does integer division here discarding anything after decimal point. So it equals 0. To fix, force compiler to do floating division: (5.0/9)
You would have same problem with first function but order of operations and fact that you are truncating result anyway saves you here.