diff --git a/app/src/main/kotlin/com/simplemobiletools/calculator/helpers/CalculatorImpl.kt b/app/src/main/kotlin/com/simplemobiletools/calculator/helpers/CalculatorImpl.kt index 69783e62..2029fcac 100644 --- a/app/src/main/kotlin/com/simplemobiletools/calculator/helpers/CalculatorImpl.kt +++ b/app/src/main/kotlin/com/simplemobiletools/calculator/helpers/CalculatorImpl.kt @@ -228,6 +228,10 @@ class CalculatorImpl(calculator: Calculator, private val context: Context) { val partial = baseValue / (100 / secondValue) baseValue.minus(partial) } + PERCENT -> { + val partial = (baseValue % secondValue) / 100 + partial + } else -> baseValue / (100 * secondValue) } }