How bit endianness affects bitwise shifts and file IO in C?

前端 未结 5 1881
有刺的猬
有刺的猬 2021-01-02 23:33

Let L and B be two machines. L order its bits from LSB (Least Significant Bit) to MSB (Most Significant Bit) whil

5条回答
  •  离开以前
    2021-01-03 00:29

    Bit-shifting is not affected by endianness. Binary file I/O normally is, but not in your case since you are only writing a single byte.

提交回复
热议问题