Question: Using a 16-bit word, find the binary representation of -47 in two's complement ones' complement sign-magnitude Assume that a short is represented by 11 bits

Using a 16-bit word, find the binary representation of -47 in two's complement ones' complement sign-magnitude Assume that a short is represented by 11 bits and an int is represented by 17 bits. What is the output generated by the following code segment: int x = 5123: int y = -5123: short sx = (short)x: short sy = (short)y: printf("%d %d %d %d ", x, y, (int)sx, (int)sy): printf("%x %x %x %x " > x, y, (int)sx, (int)sy): printf("%u %u %u %u " > x, y, (int)sx, (int)sy)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
