Horner's rule for two-variable polynomial
问题 Horner's rule is used to simplify the process of evaluating a polynomial at specific variable values. https://rosettacode.org/wiki/Horner%27s_rule_for_polynomial_evaluation#Standard_ML I've easily applied the method using SML, to a one variable polynomial, represented as an int list: fun horner coeffList x = foldr (fn (a, b) => a + b * x) (0.0) coeffList This works fine. We can then call it using: - val test = horner [1.0, 2.0, 3.0] 2.0; > val test = 17.0 : real Where [1.0, 2.0, 3.0] is the