Hmm, i understand the logic now, but there is this small thing I dont
understand
Math.round(100.2/0.15)*0.15)
results in 100.2 it should actually be 100.15...
Is it possible to get this result, can somebody please help me out (again)
Jiri
Hans Wichman wrote:
Hi,
sonething like:
trace (Math.round(100.1/0.15)*0.15);
trace (Math.round(100.35/0.5)*0.5);
trace (Math.round(100.175/0.125)*0.125);
greetz
JC
On Jan 8, 2008 10:05 AM, Jiri Heitlager <[EMAIL PROTECTED]>
wrote:
Hello,
i am not at all a mathematic/calculus wonder and would therefore like
some help with the following.
I need to round numbers up or down to a certain step size. As an example:
nVal = 100,1
nStep = 0,15
outcome = 225,15
nVal = 100,35
nStep = 0,5
outcome = 100,5
nVal = 100,175
nStep = 0,125
outcome = 100,125
I just havent got a clue on how to approach this problem. Can somebody
shed some light on a possible way to go?
Thank you,
Jiri
_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders