# Why is binary subtraction referred to as the invert-add-shift-add method?

I'm being asked this question for my computer conceptes class, can't find anything about this in my text book, and have only been able to find half-baked answers googling it.

Why is binary subtraction referred to as the invert-add-shift-add method?

-
I think it's a silly question (on behalf of your instructor). I'd prefer the name "complement-add". –  Yuval Filmus Feb 4 '13 at 0:44

## 1 Answer

I found an excellent answer here, which I summarize below.

Given two number $A,B$ in binary notation, we calculate $A-B$ by adding to $A$ the two's complement of $B$. Since the two's complement of $B$ is formed by inverting all bits of $B$ and adding $1$, one way to implement this idea is invert $B$, add the result to $A$, shift the carry $1$ bit (which will appear if $A\geq B$), and add it (i.e. $1$) to the result.

-
In addition to the above you can watch this video (Two's Complement Part 2 - An Introduction) on YouTube described the procedure clearly and completly! –  Reza Feb 4 '13 at 5:13