Yea I know what it does. My point is wouldn't it be more useful if m%n worked the way it does now for all n where n≠1, but when n=1 it returns the fractional part, since right now it only returns 0.
I understand why it only returns 0, I just think that it would be more useful if for the specific case m%1 the return value is the fractional part of m.
In reply to Re^2: modulo 1 (%1) and fractional part of a number
by JBCookin
in thread modulo 1 (%1) and fractional part of a number
by JBCookin
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |