Sobes.tech
Junior — Middle

Какое отличие между порядком байтов в системах big-endian и little-endian?

sobes.tech AI

Answer from AI

Big-endian and little-endian are two ways of ordering bytes in multi-byte numbers:

  • Big-endian: the most significant byte is stored at the lowest memory address, i.e., first.
  • Little-endian: the least significant byte is stored at the lowest memory address.

For example, the number 0x12345678 in memory would look like this:

  • Big-endian: 12 34 56 78
  • Little-endian: 78 56 34 12

This is important when transferring data between systems with different byte orders or when working with low-level code.