While coding today, I was a little surprised to discover that the div
operator doesn't coerce its arguments to integers.  So for example, the
expressions 25 div '5' and pi div 5 raise errors.  I checked the Operators
doc page and saw that, sure enough, div (and mod, I found) accept only
actual Ints.  Of all numeric operators at the multiplicative and additive
levels of precedence, they're alone in that respect.

Is there a particular reason these two operators are so restrictive?

Reply via email to