Browse Source

addition full adder complete sum without carry

master
Dennis Sperzel 11 months ago
parent
commit
7db5125bda
  1. 2
      src/addition.c

2
src/addition.c

@ -2,5 +2,5 @@
#include <stdlib.h> #include <stdlib.h>
void full_adder (int* sum, int* nextcarry, int number1, int number2, int carry) { void full_adder (int* sum, int* nextcarry, int number1, int number2, int carry) {
sum[0] = carry;
sum[0] = number1 ^ number2 ^ carry;
} }
Loading…
Cancel
Save