
-----------------------------------
Neo
Tue Nov 23, 2004 10:20 pm

Rounding
-----------------------------------
How would I round a number to the nearst ten. Say I had 12 I want it to be changed to 10 or say I had 115 then I would want it to be 120. I looked in turing reference and can only find the floor and ceiling function to round a real number to an int.

-----------------------------------
zylum
Tue Nov 23, 2004 11:18 pm


-----------------------------------
first you would want to divide by ten, then round and then multiply by ten again  :wink:

-----------------------------------
Neo
Tue Nov 23, 2004 11:31 pm


-----------------------------------
Thanks, Im an idiot.
