Re:What Every Computer Scientist Should Know About Floating-...
by ColinWright on Monday June 29, 2020 @07:08AM
(#23676410)
I don't understand your confusion.
Consider, system A has a float in memory, and wants to send it to system B. System A has no knowledge of how system B stores floats, whether it's big-endian or little-endian, how many bits of precision it uses, etc.
It might also be that the only method of transmitting information is via a text encoding ... perhaps JSON, perhaps something else.
So system A "prints" the float, converts it to a string, and sends that. It's even useful because it can be inspected "by eye" on the way through.
Now system B receives the string and converts it to a float.
All this sort of thing happens in the real world, and is sometimes dictated by the original designs of the system, and sometimes it's specified by customers that this is how it has to work.
Does that help you to understand the original comment?
Consider, system A has a float in memory, and wants to send it to system B. System A has no knowledge of how system B stores floats, whether it's big-endian or little-endian, how many bits of precision it uses, etc.
It might also be that the only method of transmitting information is via a text encoding ... perhaps JSON, perhaps something else.
So system A "prints" the float, converts it to a string, and sends that. It's even useful because it can be inspected "by eye" on the way through.
Now system B receives the string and converts it to a float.
All this sort of thing happens in the real world, and is sometimes dictated by the original designs of the system, and sometimes it's specified by customers that this is how it has to work.
Does that help you to understand the original comment?