Lets say I work in a 32 bit machine. With reference to MSB (most significant bit) which is the sign bit, my question is how is it represented for this archietecture.
My understanding is that every byte has a sign value. So if this is the case then there would be four signed bits. Am I correct or missing something here. Thanks!
Bytes are groups of bits. They don’t have any inherent meaning, and neither do the bits that make them up. Meaning is only given if you e.g. choose to interpret these four bytes as a signed integer, and then the bits mean what they mean because the platform designers say so.
In practically all prevalent architectures, integers are represented using two’s complement. This means that: