|
From: | Wolfgang Laun |
Subject: | Re: [bug-gawk] Awk cannot properly deal with too small numbers. |
Date: | Sat, 16 Apr 2016 16:22:48 +0200 |
On 15-04-16 02:21, Wolfgang Laun wrote:
Note that this works:
$ echo 1.1e-309 | awk '$1+0 < 0.05{ print $1;}'
1.1e-309
Because of this
$ echo 1.1e-309 | awk '$1 < 2.05{ print $1;}'
1.1e-309
and similar experiments I'd call the difference in behaviour surprising.
$ echo 1.1e-309 | awk '{ print $1, $1+0, $1+0<0.05, $1<2.05;}'
1.1e-309 0 1 1
$1+0 equesl 0, which is smaller than 0.05
'1.1e-309' seems to be smaller than 2.05 also ....
but nothing surprising here....
[Prev in Thread] | Current Thread | [Next in Thread] |