to prevent anyone answering on this thread:
after toying with it again, and reading the docs + wikipedia I figured out that I can only trust a result of 15 digits or less, unless I have the string be returned instead of the number.

n 12/18/2010 8:34 PM, Anthony Pace wrote:

function floatSumV3(roundDown:Boolean = true, ... nums):Number{
    var nl:uint = nums.length;
    var ls:Number=0; //left side
    var pp:int; //period position
    var rs:Number = 1; //right side
    var rsl:int; //right side length
    var ml:int = 0; //max length right side
    var powerCounter:int = 1;
    var powerResult:int;
    var s:String;
    for (var i:int = 0; i< nl; ++i) {
        s = nums[i].toString();
        pp = s.indexOf('.');
        if(pp!=-1){
            rsl = s.length - pp-1;
            if(rsl>ml){
                p

_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to