Jump to content

Four bit adder: Difference between revisions

m
C: add comment about xor
(use of xor operator was forbidden for this task -- Undo revision 84068 by 169.232.246.15 (Talk))
m (C: add comment about xor)
Line 30:
#define NOT(X) (~(X)&0x01)
#define XOR(X,Y) ((NOT(X)&(Y)) | ((X)&NOT(Y)))
/* XOR would be (X^Y) if that were not forbidden by this task */
 
void halfadder(IN a, IN b, OUT s, OUT c)
6,962

edits

Cookies help us deliver our services. By using our services, you agree to our use of cookies.