How to get numbers after commas in Excel
How to get numbers after commas in Excel. A rational number consists of two parts, an integer and a decimal. The whole part is the part before the comma, the part after the comma is called a decimal. Excel does not have specialized tools or functions to get numbers after commas. However, you can use the built-in tools to calculate whole and decimal parts.
A rational number consists of two parts, an integer and a decimal. The whole part is the part before the comma, the part after the comma is called a decimal. Excel does not have specialized tools or functions to get numbers after commas. However, you can use the built-in tools to calculate whole and decimal parts.
Use the TRUNC function to get the number before the comma
To get the part before the comma is very simple, you use the TRUNC function to truncate the part after the comma with the following syntax:
= TRUNC (number, [num_digits]).
Inside:
- TRUNC: is the name of the function used to round a number to an integer by removing its decimal part.
- Number: the original number.
- Num_digits: A number that identifies the precision of truncation. The default value for num_digits is 0 (zero).
Note that INT and TRUNC are also functions that take integers. However, the INT function rounds down to the nearest integer based on the value of the fractional part of that number. While the TRUNC function takes an integer part by removing its fractional part.
The INT and TRUNC functions differ only when the original number is negative. TRUNC (-10.25) = -10 while INT (-10.25) = -11.
Get the number after the comma
After you get the number before the comma (whole part) with the TRUNC function, you subtract the result of the TRUNC function and get the decimal.
Combining the steps above, you can always use the following formula:
= rational numbers - TRUNC (rational numbers) .
In which rational numbers can be a position of cells containing data or a number to round. With the above formula, you get the same result:
If you want the result to be a positive number, you use the ABS function to return the absolute value of the result by the formula = ABS (rational number - TRUNC (rational number)) .
Above Software Tips showed you how to take the number after the comma in Excel. Good luck!
Discover more
Share by
Samuel DanielYou should read it
- How to convert commas into dots in Excel
- Convert commas to dots in Excel
- Instructions to stamp negative numbers in Excel
- How to Replace Comma with Period in Excel
- How to separate text strings by commas or spaces in Excel
- The Quiet Details That Make a Sports Betting Platform Feel Reliable
- Instructions on creating toy set images with ChatGPT AI
- How are AI agents changing the journalism industry?
- How to delete cells in Excel
- How to convert formulas to values in Excel
- How to convert hours to minutes in Excel