lua-users home
lua-l archive

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


2018-05-21 22:47 GMT+02:00 Egor Skriptunoff <egor.skriptunoff@gmail.com>:

> That's why in Lua we have an unpleasant surprise:
> - a%m - b%n ~= - b%n - a%m
> It's looks very weird.
> That should be an equality as in all other programming languages.

All? Let's try APL.

      a←10 ⋄ b←20 ⋄ m←3 ⋄ n←4
      -a|m-b|n
¯9
      -b|n-a|m
¯1