ofc, but it is possible for compiler to be smart enough to"discover" this? and use similar heuristics for other similar problems?
Personally I don’t ever want a compiler trying to replace straight-forward integer algorithms with floating point formulas. YMMV.