http://qs321.pair.com?node_id=1016167


in reply to IEEE-754 calculation - best way?

This is really 2 questions
  1. How do I calculate values all adhering to IEEE-754?
  2. How do I display an IEEE-754 value accurately?
Perl uses double or long double as its internal data format, depending on how it's built. It's going to do 754-compliant calculations.

The only way you can control how the value is displayed is via a mechanism that allows you to specify what you want. Things like printf/fprintf/sprintf (or something like Number::Format).

fnord