The Gateway to Computer Science Excellence

+23 votes

$(C012.25)_H - (10111001110.101)_B =$

- $(135103.412)_o$
- $(564411.412)_o$
- $(564411.205)_o$
- $(135103.205)_o$

+38 votes

Best answer

$(C012.25)_H - (10111001110.101)_B $

$= 1100\;0000\;0001\;0010.\;0010\;0101$

$- 0000\;0101\;1100\;1110.\;1010\;0000$

$= 1011\;1010\;0100\;0011.\;1000\;0101$

$= 1\;011\;101\;001\;000\;011 .\;100\;001\;010$

$= (135103.412)_o$

Binary subtraction is like decimal subtraction:$ 0-0 = 0, 1-1 = 0, 1-0 = 1, 0-1 = 1$ with $1$ borrow.

Correct Answer: $A$

$= 1100\;0000\;0001\;0010.\;0010\;0101$

$- 0000\;0101\;1100\;1110.\;1010\;0000$

$= 1011\;1010\;0100\;0011.\;1000\;0101$

$= 1\;011\;101\;001\;000\;011 .\;100\;001\;010$

$= (135103.412)_o$

Binary subtraction is like decimal subtraction:$ 0-0 = 0, 1-1 = 0, 1-0 = 1, 0-1 = 1$ with $1$ borrow.

Correct Answer: $A$

+1

@arjun Sir

1

1100 0000 0001 0010. 0010 0101

0000 0101 1100 1110. 1010 0000

0 1 1

Sir here the number after decimal point is (0-1) which will give 1 and borrow of 1

then (1-0) = 1

so next digits are (1-1) = 0 na ?

where am i going wrong

1

1100 0000 0001 0010. 0010 0101

0000 0101 1100 1110. 1010 0000

0 1 1

Sir here the number after decimal point is (0-1) which will give 1 and borrow of 1

then (1-0) = 1

so next digits are (1-1) = 0 na ?

where am i going wrong

+6

If someone is having difficulty like me with subtraction, carry & borrow we can use 2's complement method

0000 0101 1100 1110. 1010 0000

1111 1010 0011 0001. 0101 1111 (1's compliment)

Now in this we don't add 1 but we add 0.0000 0001 ref https://stackoverflow.com/questions/21367400/subtraction-of-binary-fractions-using-2s-complement

1111 1010 0011 0001. 0110 0000

Now add this with first number you will get same answer as above

+11 votes

Another way:

convert the binary in hexadecimal,

0101 1100 1110.1010 = (5CE.A)_{H}

Now we'll do hexadecimal subtraction,

C 0 1 2. 2 5

- 0 5 C E. A 0

-------------------

B A 4 3. 8 5_{H}= 1011 1010 0100 0011. 1000 0101 = 001 011 101 001 000 011. 100 001 010 = (135103.412)_{o}

-------------------

Note: when 2_{H }borrow, it becomes (2+16) = 18 in decimal = 12_{H}

and 18 - A(or 10) = 8

52,375 questions

60,554 answers

201,953 comments

95,374 users