Junior — Middle
Can you explain what the big-endian byte order means when storing data in memory?
sobes.tech AI
Answer from AI
Big-endian byte order is a method of storing multi-byte numbers in memory, where the most significant byte is stored at the smallest memory address, i.e., at the beginning of the sequence. For example, a 32-bit number 0x12345678 in memory will be stored as:
Address: 0x00 0x01 0x02 0x03
Value: 0x12 0x34 0x56 0x78
This is opposite to little-endian, where the least significant byte is stored first. Big-endian is often used in network protocols (network byte order) and some processor architectures.