Reversing byte order in .NET

后端 未结 7 1151
天命终不由人
天命终不由人 2020-12-03 11:29

In the code below, why do X and Y take on different values than what I would think intuitively?

If the bytes 0-7 are written to the buffer, shouldn\'t the resulting

7条回答
  •  半阙折子戏
    2020-12-03 12:09

    BinaryReader assumes Little Endian order: http://msdn.microsoft.com/en-us/library/system.io.binaryreader.readint64.aspx

提交回复
热议问题