[Gambas-user] Infinities and division
Jussi Lahtinen
jussi.lahtinen at gmail.com
Tue Nov 29 19:52:48 CET 2022
... also this would be consistent with not allowing divide by zero (which
would be kinda x / 0 = infinity).
And furthermore this would prevent illogical things like:
If infinite / 1 = infinite / 2 Then Print "Yes, 1 is totally equal to 2."
Jussi
On Tue, Nov 29, 2022 at 8:41 PM Jussi Lahtinen <jussi.lahtinen at gmail.com>
wrote:
> But should it raise an error in that case, or return the infinites?
>>
>
> I would follow mathematical logic. Infinite / x and x / infinite are not
> defined and thus error should be raised.
>
> Jussi
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20221129/2adacab3/attachment.htm>
More information about the User
mailing list