Replies to message #2,567

  • 🔎 If you see an alert for analytics.usips.org, this is a self-hosted system I am running as a test. It is GDPR compliant and collects no invasive information.
byuu

Programming thread

But it is mathematically correct under the rules of modular arithmetic.
Kosher Salt

Programming thread

-2 divided by 10 isn't -1 with a remainder of 8. It's 0 with a remainder of -2. If you want a guaranteed positive remainder, you can always do (i...
Knight of the Rope

Programming thread

You mean floored, right? I thought you made a typo at first but it's odd that you'd make the same typo across two different posts. Otherwise I...
Fcret

Programming thread

The modulo operator in Java and C is optimized for speed, not correctness. This speed is important for things like cryptographic libraries. If you...
Back
Top Bottom