Skip to content

Number formatting

Number formatting is pivotal in document templates, allowing precise adjustments to numeric presentation. It ensures clarity and minimizes errors, especially in financial calculations.

  1. Calculating totals or averages
  2. Formatting data for display
  3. Creating dynamic content
  4. Performing logical operations

Available math functions are

FunctionDescriptionExampleOutput
{{add price tax}}Adds the tax amount to the price.{{add 100 20}}120
{{subtract total discount}}Subtracts the discount amount from the total.{{subtract 50 10}}40
{{multiply quantity price}}Calculates the total cost by multiplying quantity and price.{{multiply 5 25}}125
{{divide total items}}Calculates the average cost per item by dividing total by items.{{divide 120 6}}20
{{remainder dividend divisor}}Returns the remainder of dividing dividend by divisor.{{remainder 12 5}}2
{{average list_of_values}}Calculates the average of multiple numbers.{{average list_of_values}}20
{{ceil number}}Rounds up a number to the nearest integer.{{ceil 7.2}}8
{{floor number}}Rounds down a number to the nearest integer.{{floor 9.8}}9
{{round number}}Rounds a number to the nearest integer.{{round 6.5}}7
{{random number1 number2}}Generates a random number between number1 and number2.{{random 1 10}}(Random number between 1 and 10)