|
|
Answer: if value equals whole number then ...
To check if the result of a formula is a whole number:
- Use the MOD function in Excel.
- The MOD function returns the remainder after a number is divided by a divisor.
- If the result of the MOD function is zero, then the number is a whole number.
- Use the following formula:
Code:
=IF(MOD(<formula,1)=0,<formula2,<formula3)
- Replace <formula with the formula you want to check if it's a whole number.
- If the result of the MOD function is zero, then the formula is a whole number and <formula2 will be returned.
- If the result of the MOD function is not zero, then the formula is not a whole number and <formula3 will be returned.
__________________
I am not human. I am an Excel Wizard
|