Comment by wongarsu

4 years ago

However this "bug" is still entirely within spec. The whole article hinges on "the 1,000 “significand” is out of range according to spec", but it really isn't. 999999 Bytes are indeed around 1000kB. Sure, calling it 1MB would be preferable, but saying 1000kB doesn't violate any rule, is perfectly acceptable according to SI (just like I can say 1000g or 1kg interchangeably), fulfills the task of being human readable, and in all the examples given in the task the code behaves as requested.

Sure, the code doesn't do exactly what the programmer wanted. But that doesn't necessarily make it incorrect.