in reply to How to get rounded numbers to =100% ??

Something else you may look into is separating your mantissa (display) from your value. you can keep the true number in one variable with high precision, then round the number off using sprintf.
Real value        displayed
   _
33.3               33.33 %
   _
66.6               66.67 %
   _      _
33.3 + 66.6        100.00 %

The trick is to get perl to store the real values at the highest precision possible. I may not have expressed myself very well here, so someone else feel free to elaborate.

hattmoward - mhoward%at%hattmoward.org
  • Comment on Re: How to get rounded numbers to =100% ??

Replies are listed 'Best First'.
Re: Re: How to get rounded numbers to =100% ??
by alarix (Initiate) on May 22, 2003 at 14:42 UTC
    I thought about this actually, but haven't got around to trying it out yet. But I think that's essentially what artist's Dominus reference is doing.