![](https://codky.com/wp-content/uploads/2024/11/13391-1024x576.png)
The TRUNC function in Excel is used to truncate a number by removing the decimal portion, effectively cutting it off without rounding. Here’s how you can use the TRUNC function:
Syntax:
TRUNC(number, [num_digits])
- number: This is the number you want to truncate.
- [num_digits]: This is an optional argument. It specifies the number of decimal places to which you want to truncate the number. If omitted, it defaults to 0, meaning it will truncate to an integer.
Steps to Use TRUNC Function:
- Open Excel: Open your Excel workbook and navigate to the cell where you want the result of the TRUNC function.
- Enter the Function: Click on the cell and type `=TRUNC(`.
- Provide Arguments:
- Enter the number or the cell reference that contains the number you wish to truncate.
- If you want to specify the number of decimal places, type a comma followed by the number of decimal places.
Example:
- Close the Parentheses: Complete the function by closing the parentheses and press `Enter`.
Examples:
=TRUNC(123.987)
- Truncate to Integer:
This will return `123`.
=TRUNC(123.987, 2)
- Truncate to Two Decimal Places:
This will return `123.98`.
- Using Cell References:
Suppose cell A1 contains `45.6789`.
=TRUNC(A1, 1)
This will return `45.6`.
Notes:
- Unlike the `ROUND` function, TRUNC simply slices off the decimal digits and does not perform any rounding.
- TRUNC is useful when you need to eliminate the fraction of a number, especially when dealing with issues that require dropping without rounding, like certain financial calculations.
By following these steps and understanding the syntax, you’ll be able to efficiently use the TRUNC function to process numbers in Excel according to your needs.