[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [bug-gawk] Error Gawk Manual FP Precision

From: Andrew J. Schorr
Subject: Re: [bug-gawk] Error Gawk Manual FP Precision
Date: Mon, 20 Aug 2018 15:59:53 -0400
User-agent: Mutt/1.5.21 (2010-09-15)

On Mon, Aug 20, 2018 at 05:49:27PM +0200, Jannick wrote:
> The following simple version of the function within_delta should work:
> function within_delta(a, b, delta)
> {
>       return abs(a - b) < abs(delta) # note the '<'-sign
> }

Yes, but isn't delta known to be positive?
In other words, why isn't
   abs(a-b) < delta
an adequate test?


reply via email to

[Prev in Thread] Current Thread [Next in Thread]