hexadecimal addition, what does it mean to “add 0x1000000 – 1” for example?

460 viewsMathematicsOther

hexadecimal addition, what does it mean to “add 0x1000000 – 1” for example?

In: Mathematics

4 Answers

Anonymous 0 Comments

If you think about hexadecimal like decimal, you count `0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F` which is equal to `0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15`

Like decimal math, if you take 1 away from 0, there must be a digit in the next place to “give” the lower place a value.

So decimal math, `100 – 1`. `0-1` forces to borrow 1 from the 10s place and then again from the 100s place, making `99`.

Similarly, `x100 – 1`. `0-1` forces 1st digit to borrow from the 2nd digit and, since the 2nd place is 0, again from the 3rd. Instead of becoming `9`, those places become the highest value of hex, making `x0FF`

Now apply that to your problem. `x1000000 – 1 = x0FFFFFF`

You are viewing 1 out of 4 answers, click here to view all answers.