Working in little endian, which is excatly (including eof if there is) the bit representation of a C vector like this?
unsigned char vet[] = {0x0f, 0x05};
Working in little endian, which is excatly (including eof if there is) the bit representation of a C vector like this?
unsigned char vet[] = {0x0f, 0x05};
Bit representation of a vector of unsigned char
s is not dependent on endianness, because char
types are single-byte, while endianness tells you how multiple bytes are arranged in memory.
Therefore, 0x0f
would be found at an earlier address in memory than 0x05
, producing
0000111100000101
including eof if there is [one]
Unlike C strings and arrays initialized with C strings, arrays initialized with curly brace initializers do not have an end mark.
Well, so if vector is:
unsigned char vet[] = { 0xBC,0xFF,0x01 }
Bit representation should be:
101111001111111100000001
And its length is 24 bit because there is no end mark, rigth?