From 1c4c48654e693fc3eb0f79c127c3ee21304dd13c Mon Sep 17 00:00:00 2001 From: fdai7782 Date: Wed, 7 Feb 2024 19:09:22 +0000 Subject: [PATCH] Changed the parameter name from operation to operationType in the function performOperation in the programmingMode.c file and also in the calculator.h file --- src/main/c/calculator.h | 2 +- src/main/c/programmingMode.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main/c/calculator.h b/src/main/c/calculator.h index a559fa6..0a34ca1 100644 --- a/src/main/c/calculator.h +++ b/src/main/c/calculator.h @@ -85,6 +85,6 @@ double ConClock(double time, int startingUnit, int endingUnit); double ConTime(double time, int startingUnit, int endingUnit); -int performOperation(int num1, char operator, int num2); +int performOperation(int num1, char operatorType, int num2); #endif // CALCULATOR diff --git a/src/main/c/programmingMode.c b/src/main/c/programmingMode.c index 40da798..f9a4ebb 100644 --- a/src/main/c/programmingMode.c +++ b/src/main/c/programmingMode.c @@ -22,8 +22,8 @@ char getOperatorInput() { } // Calculation -int performOperation(int num1, char operator, int num2) { - switch (operator) { +int performOperation(int num1, char operatorType, int num2) { + switch (operatorType) { case '+': return num1 + num2; case '-':