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.