title: How to convert float to byte array of length 4 (array of char*)?
body: <p>How to convert float to byte array of length 4 (array of char*) ? I need to send over network some data, tcp, and need to send float as a byte array. ( I know precision to two decimal digits, so at the moment I on client side multiply by 100 and on server divide by 100  - basically convert to integer and then find bytes with &amp; 0xff   &lt;&lt; operations). But it is ugly and can lost precision during time.</p>