Re:Julia 1.0
by simonbyrne on Thursday August 09, 2018 @07:57PM
(#17729591)
I take the opinion that people should have the option to round division (and compute remainders) however they want: down, up, to zero, to nearest (with different options for breaking ties).
Re:Julia 1.0
by ScottBurson on Friday August 10, 2018 @05:35PM
(#17736911)
Common Lisp has all four division operators ('floor', 'ceiling', 'truncate' (equivalent to what most languages consider division), and 'round') [0], and both 'mod' and 'rem' [1].
[0] http://www.lispworks.com/documentation/lw50/CLHS/Body/f_floo...
[1] http://www.lispworks.com/documentation/lw50/CLHS/Body/f_mod_...
I don’t know what is available as chip instructions, I could certainly believe hardware designers made the wrong choice.