From e1f9c4c384fa592f4f8a3bf5fb7377195e11ad5d Mon Sep 17 00:00:00 2001 From: Ulriche Nguefack Date: Mon, 5 Feb 2024 20:53:11 +0100 Subject: [PATCH] case modulus --- src/main/c/Calculator/calculator.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/main/c/Calculator/calculator.c b/src/main/c/Calculator/calculator.c index da9d5f1..b7f10ce 100644 --- a/src/main/c/Calculator/calculator.c +++ b/src/main/c/Calculator/calculator.c @@ -57,6 +57,12 @@ int main() { scanf("%lf %lf", &num1, &num2); result = exponent(num1, num2); printf("Result: %lf\n", result); + break; + case 6: + printf("Enter two numbers: "); + scanf("%lf %lf", &num1, &num2); + result = modulus(num1, num2); + printf("Result: %lf\n", result); break; case : printf("Exiting...\n");