modulo

Brendan Eich brendan at mozilla.com
Sat Sep 21 13:21:24 PDT 2013


Since no one else replied, I will take a stab.
> raul mihaila <mailto:raul.mihaila at gmail.com>
> September 17, 2013 2:46 PM
> If I understand correctly, q = floor(x / y), in x - k = q x y, where k 
> = x modulo y. If this is correct I think that such a note would be 
> nice to have for non-mathematicians. :)

It follows from 5.2, Algorithm Conventions, specifically:

The mathematical function floor(x) yields the largest integer (closest 
to positive infinity) that is not larger than x.

NOTE floor(x) = x−(x modulo 1).

/be
>
> Raul M
> _______________________________________________
> es-discuss mailing list
> es-discuss at mozilla.org
> https://mail.mozilla.org/listinfo/es-discuss


More information about the es-discuss mailing list