lua-users home
lua-l archive

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

> There are several variants of modulo operations,[1] and the documentation
> isn't very clear on which variant is used by Lua. [...]

The manual says (3.4.1):

   Modulo is defined as the remainder of a division that rounds the
   quotient towards minus infinity (floor division).

I think that defines univocally what variant Lua uses.

-- Roberto