Hacker News new | past | comments | ask | show | jobs | submit login

It may not be precise in its details but it's a very accessible explanation that's certainly "good enough." Maybe you could swap it in for "non-whole numbers" and still be reasonably accessible, but that's also not perfectly accurate since integers are stored just fine inside a float.

I'm certainly not going to fault them for using layman terms when addressing laymen.




Ideally for this work you want somebody who is capable of communicating in a way that doesn't feel dumbed down and yet also isn't actively wrong. This explanation of the floating point types does not hit that mark. I'm not in the market for an Odin book, so in some sense it doesn't matter what I think, but across fields it's better if what you're saying is able to both serve its immediate purpose and actually true.

People are going to remember (some of) what you taught them and even if it felt peripheral at the time they may have centred it. When they return to this teaching again, it's not surprising that they assume you meant what you said, even if in your mind it was figurative or targeted at a superficial understanding of the subject.

Decimal representations do exist in machines. Representations that can manage 1.2 exactly but can't handle a third, or pi, or the square root of 2 for example. But the floating point numbers aren't that, they're a weird (but useful) binary fraction and if we're going to mention them at all we need to make it clear what's going on here.

For example the "float" (32-bit IEEE floating point type) called 1.2 is actually 5033165 divided by 4194304 which isn't actually six over five (1.2) but it's pretty close.




Consider applying for YC's Summer 2025 batch! Applications are open till May 13

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: