Converting Signed Hex to Decimal: What is the Correct Solution for -8230?

  • Thread starter Thread starter Sumaya
  • Start date Start date
  • Tags Tags
    Convert
AI Thread Summary
To convert the signed hex value 8230 to decimal, the correct process involves using two's complement since the value is negative. The mistake identified is in the calculation of the two's complement; the correct ones' complement of 8230 is 7DCF, and adding 1 results in 7DD0, which converts to -32208 in decimal. The initial calculation incorrectly led to -32214. The discrepancy between the calculated value and the book's answer highlights the importance of accurately performing the two's complement conversion.
Sumaya
Messages
29
Reaction score
0

Homework Statement



convert signed hex to decimal, 8230

Homework Equations





The Attempt at a Solution




i first make 2's complement of 8230 bcz it is negative

then i convert it to decimal

ffff-8230=7dcf+1=7dd6
7dd6=32214 in decimal

my answer is -32214

but i checked the solution on the book ,it was different .. -32208
i want to know where is my mistake ?
did i do the steps of the converstion right ?


thanx a lot ...
 
Physics news on Phys.org
Sumaya said:

Homework Statement



convert signed hex to decimal, 8230

Homework Equations





The Attempt at a Solution




i first make 2's complement of 8230 bcz it is negative

then i convert it to decimal

ffff-8230=7dcf+1=7dd6
The above has a mistake.
The ones' complement of 8230 is 7DCF. Adding 1 gives you 7DD0, which is 32208 in base-10.
Sumaya said:
7dd6=32214 in decimal

my answer is -32214

but i checked the solution on the book ,it was different .. -32208
i want to know where is my mistake ?
did i do the steps of the converstion right ?


thanx a lot ...
 
thnx alot
 
Back
Top