Skip to main content

FFH AND C0H; (16)₁₀ − (26)₁₀ by 2's complement

Short answer

FFH AND C0H = C0H. For subtraction: 16=00010000, 26=00011010; 2's complement of 26 is 11100110. Add: 00010000+11100110=11110110. No end carry, result is negative; 2's complement of sum is 00001010, so answer is -10.

When FFH is ANDed with C0H what will be the resulting number? Subtract (26)₁₀ from (16)₁₀ using 2's complement binary method.

FFH AND C0H

AND each bit pair:

 FFH = 1111 1111
 C0H = 1100 0000
 AND = 1100 0000

Answer: FFH⋅C0H=C0HFF_H \cdot C0_H = C0_H. (ANDing with FFHFF_H leaves the other number unchanged.)

(16)₁₀ − (26)₁₀ by 2's complement (8-bit)

16=0001 000026=0001 10102’s complement of 26=1110 0101+1=1110 0110\begin{aligned} 16 &= 0001\,0000 \\ 26 &= 0001\,1010 \\ \text{2's complement of } 26 &= 1110\,0101 + 1 = 1110\,0110 \end{aligned}
   0001 0000   (+16)
 + 1110 0110   (-26)
 -----------
   1111 0110   (no end carry)

No end carry, so the result is negative. Its magnitude is the 2's complement of the sum:

1111 0110‾+1=0000 1001+1=0000 1010=10\overline{1111\,0110} + 1 = 0000\,1001 + 1 = 0000\,1010 = 10

Answer: 16−26=1111 011016 - 26 = 1111\,0110 (2's complement form) =−10= -10.

✓ Answer checked by Claude Opus 5.5 (high effort)

All Digital Logic chapter 5 questions →