You are viewing a single comment's thread. Return to all comments →
Thank you for the tip. I also noticed the overflow but wondered why the compiler did not adjust the size of the operations to the function output.
So it also works by casting the volume multiplication :
return (long)l * (long)b * (long)h;
Seems like cookies are disabled on this browser, please enable them to open this website
Box It!
You are viewing a single comment's thread. Return to all comments →
Thank you for the tip. I also noticed the overflow but wondered why the compiler did not adjust the size of the operations to the function output.
So it also works by casting the volume multiplication :
return (long)l * (long)b * (long)h;