• Calculates n rounded to precision.

    Parameters

    • n: number

      The number to round.

    • Optionalprecision: number

      The precision to round to.

    Returns number

    Returns the rounded number.