From 7db5125bda9a89408ac765e6a9340eed5342cc62 Mon Sep 17 00:00:00 2001 From: Dennis Sperzel Date: Mon, 29 Jan 2024 20:00:12 +0100 Subject: [PATCH] addition full adder complete sum without carry --- src/addition.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/addition.c b/src/addition.c index 192513a..753d77d 100644 --- a/src/addition.c +++ b/src/addition.c @@ -2,5 +2,5 @@ #include void full_adder (int* sum, int* nextcarry, int number1, int number2, int carry) { - sum[0] = carry; + sum[0] = number1 ^ number2 ^ carry; } \ No newline at end of file