Solve the following operation with binary numbers. Check your answer by converting the binary numbers to base 10 numbers, doing the operation on the base 10 numbers, and converting the answer back to base 2.

11001012
- 101012

1 answer

To solve this operation with binary numbers, you can subtract each digit starting from the right to the left, borrowing if necessary.

1. Start from the rightmost digits and subtract them:
1 - 0 = 1

2. Move to the next digits and subtract them, taking into account the borrowed digit (1):
0 - 1 (borrowed) = -1. Since -1 is not a valid binary digit, we will borrow from the next digit.
The digit becomes 10 (the borrowed 1 plus the original 0), and we subtract 1 from it.

10 - 1 = 1

3. Move to the next digits and subtract them:
0 - 0 = 0

4. Continue subtracting the remaining digits:
0 - 1 (borrowed) = -1
The digit becomes 10 (the borrowed 1 plus the original 0), and we subtract 1 from it.

10 - 1 = 1

5. Finally, subtract the remaining digits:
1 - 1 = 0

Therefore, the result of the subtraction of 1100101 with 10101 is 100000.

To check this answer, let's convert the binary numbers to base 10, do the operation on the base 10 numbers, and convert the answer back to base 2.

1100101 (base 2) = 101 (base 10)
10101 (base 2) = 21 (base 10)

The subtraction of 101 - 21 is 80 (base 10).

Converting 80 (base 10) back to base 2:
80 ÷ 2 = 40 with a remainder of 0
40 ÷ 2 = 20 with a remainder of 0
20 ÷ 2 = 10 with a remainder of 0
10 ÷ 2 = 5 with a remainder of 0
5 ÷ 2 = 2 with a remainder of 1
2 ÷ 2 = 1 with a remainder of 0
1 ÷ 2 = 0 with a remainder of 1

Taking the remainders in reverse order, the base 2 representation of 80 is 1010000.

So, the answer of the subtraction of 11001012 - 101012 is 10100002, or 80 in base 10.