Would be better, or a better alternative, to accept two integers with at least the first being 64-bits: the significant digits in one and the number of decimal places in the other; or alternatively the digits to the left in one and to the right in the other.
One of my very, very first programming experiences (1968 or so) was two friends who wrote an accounting system in PL/I (yes, 1968 or so) using floating point. Didn't end well. Charles -----Original Message----- From: IBM Mainframe Discussion List [mailto:[email protected]] On Behalf Of Tony Harminc Sent: Sunday, March 5, 2023 1:08 PM To: [email protected] Subject: Re: Common standard for number formatting equiv. to mainframe facilities? On Sun, 5 Mar 2023 at 08:32, David Crayford <[email protected]> wrote: strfmon() should do the trick. > Sigh... Binary floating point for currencies. Doesn't end well. Even Bitcoin et al expect correct decimal results. ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [email protected] with the message: INFO IBM-MAIN
