calculate Result With
open fun calculateResultWith(expr: String, vararg inputVars: Pair<String, Number>): KthParsingAndCalculationResult
Parses an arithmetic expression from the given string, then return its result.
Any unknown alphanumeric token that is not a number, an element or an input variable is considered illegal.
Return
the result of the expression
Parameters
expr
the arithmetic expression to parse
input Vars
the input variables that are used in the expression
See also
open fun String.calculateResultWith(vararg inputVars: Pair<String, Number>): KthParsingAndCalculationResult
Parses an arithmetic expression from the receiving string, then return its result.
Any unknown alphanumeric token that is not a number, an element or an input variable is considered illegal.
Return
the result of the expression
Parameters
input Vars
the input variables that are used in the expression