DigiFlop

The half adder's mirror image — difference and borrow instead of sum and carry.

Verilog Coding Exercise · Combinational I
Half Subtractor
The half adder's mirror image — difference and borrow instead of sum and carry.

Subtracts B from A for two single bits, producing a DIFF and BORROW output. Like the half adder, it has no input borrow — the full subtractor adds that.

Boolean expressionsDIFF = A ⊕ B, BORROW = A′B
▶ Try the interactive version