Adds XOR
This commit is contained in:
parent
1b1b3f4cdd
commit
627d56f1eb
|
@ -14,4 +14,7 @@ CHIP Xor {
|
|||
|
||||
PARTS:
|
||||
// Put your code here:
|
||||
}
|
||||
Nand(a=a, b=b, out=w);
|
||||
Or(a=a, b=b, out=x);
|
||||
And(a=x, b=w, out=out);
|
||||
}
|
||||
|
|
|
@ -0,0 +1,5 @@
|
|||
| a | b | out |
|
||||
| 0 | 0 | 0 |
|
||||
| 0 | 1 | 1 |
|
||||
| 1 | 0 | 1 |
|
||||
| 1 | 1 | 0 |
|
Loading…
Reference in New Issue