def horner(coeffs, x):
tot = <NUM_LIT:0><EOL>for c in coeffs:<EOL><INDENT>tot = tot * x + c<EOL><DEDENT>return tot<EOL>
r'''Simple function to calculate the value of a polynomial at a specific
    value of `x`, using the Horner evaluation scheme

    Parameters
    ----------
    coeffs : array-like
        Coefficients, where coeffs[0] is multiplied by the largest power of x,
        and coeffs[-1] is added to the sum with no multiplication.
    x : float
        Value to evaluate the polynomial at

    Returns
    -------
    y : float
        Evaluated result

    Notes
    -----
    Efficient. Faster than numpy.polyval.

    Examples
    --------
    >>> horner([1,2,3], 3)
    18