News:

As usual while waiting for the next release - don't forget to check the nightly builds in the forum.

Main Menu

rouinding up / down from a floating point number to an interger form

Started by David Marsh, August 16, 2020, 05:56:32 AM

Previous topic - Next topic

David Marsh

I have floating point calculations running which often end up in FP format but I wish to store them as INT`s for future use.

so far been unable to find any reference to this in my code books! So I need some help thanks in advance, David.

raynebc

Any decent programming book (at least for C style languages) should describe casting from one data type to another.  That's where you should start.

stahta01

C Programmer working to learn more about C++.
On Windows 10 64 bit and Windows 11 64 bit.
--
When in doubt, read the CB WiKi FAQ. [url="http://wiki.codeblocks.org"]http://wiki.codeblocks.org[/url]