On Sep 22 2025, Duncan Roe via Bug reports for the GNU Bourne Again SHell wrote:
$ printf '%g\n' $(fltexpr -p '0.1 + 0.2')
0.3
That is wrong for a value that needs more than 6 digits of precision.
Salt to taste. '%.15g' would address the OP's requirements.
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU chet@case.edu http://tiswww.cwru.edu/~chet/