[Oberon] Modulus on negative number
Aubrey McIntosh
aubrey.mcintosh at utexas.edu
Wed Feb 15 05:37:52 CET 2017
The mathematical definition is for the modulus to be positive. Oberon
calculates it this way.
On Tue, Feb 14, 2017 at 9:21 PM, Srinivas Nayak <sinu.nayak2001 at gmail.com>
wrote:
> Dear All,
>
> Recently I come across modulus on a negative number.
> Will it produce a negative number or positive?
> Someone says both are correct! http://stackoverflow.com/a/4403556
> Which one is mathematically correct?
> Surprisingly different languages calculate it differently even!
> What is Oberon's way?
>
>
> With thanks and best regards,
>
> Yours sincerely,
> Srinivas Nayak
>
> Home: http://www.mathmeth.com/sn/
> Blog: http://srinivas-nayak.blogspot.in/
> --
> Oberon at lists.inf.ethz.ch mailing list for ETH Oberon and related systems
> https://lists.inf.ethz.ch/mailman/listinfo/oberon
>
--
Aubrey McIntosh, Ph.D.
1502 Devon Circle
Austin TX 78723
(512) 348-7401
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.inf.ethz.ch/pipermail/oberon/attachments/20170214/b22f2f7d/attachment.html>
More information about the Oberon
mailing list