this post was submitted on 02 Jan 2025
809 points (99.1% liked)

Programmer Humor

32710 readers
152 users here now

Post funny things about programming here! (Or just rant about your favourite programming language.)

Rules:

founded 5 years ago
MODERATORS
 

~~Stolen~~ Cross-posted from here: https://fosstodon.org/@foo/113731569632505985

you are viewing a single comment's thread
view the rest of the comments
[โ€“] [email protected] 10 points 4 days ago (2 children)

A lot of work has gone into making floating point numbers efficient and they cover 99% of use cases. In the rare case you really need perfect fractional accuracy, it's not that difficult to implement as a pair of integers.

[โ€“] WhiskyTangoFoxtrot 19 points 4 days ago