Functional Weave
Code in Rust

math.round-div@1.0.0

README.md

316 bytes · view raw

# math.round-div

half-up rounds a half away from zero, which is what UK tax guidance and most
invoicing systems assume.

half-even is banker's rounding, used where repeated rounding must not bias
upward.

down truncates toward zero.

Every mode is defined on integers only: no float ever touches a monetary amount.