Find out sum and carry of a binary adder if previous carry is given with two bits (x and y) for addition.
Examples
Previous carry is 1 and x=y=1. Addition is 1 and carry is also 1.
Previous carry is 0 and x=y=1. Addition is 0 and carry is also 1.
Previous carry is 0 and x=1, y=0. Addition is 1 and carry is also 0.
You should maybe test all the truth table no ?
Try some logic... Instead of hard code...
7685 Solvers
It dseon't mettar waht oedrr the lrettes in a wrod are.
494 Solvers
Create a Multiplication table matrix...
226 Solvers
309 Solvers
106 Solvers