From f651fcdb4cda025c0fd79c94db83609ded0a0b8f Mon Sep 17 00:00:00 2001 From: Alex Date: Thu, 2 Apr 2026 00:59:27 +0300 Subject: [PATCH] Fixed incorrect handling of the modulo operation --- basecalc.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/basecalc.cpp b/basecalc.cpp index 9fe6768..fe8eb32 100644 --- a/basecalc.cpp +++ b/basecalc.cpp @@ -24,7 +24,7 @@ int BaseCalculator::calculate(const Operation& op) break; case OpType::Modulo: - result += op.a % op.b; + result = op.a % op.b; break; case OpType::Special: