An IF statement consists of three arguments, separated by commas: =IF(first argument,
second argument, third argument). The first argument is the test to be performed, the
second controls what happens if the test is true, and the third argument controls what
happens if the test is false. In this example, the first argument is testing whether the value
in cell A1 is between 18 and 65, inclusive. The second argument directs that if the test is
The Data Validation tool is easier to use. However, it is limited to performing tests of just
one condition. More complex tests require the IF function. For example, perhaps we want
to treat values of 18, 19, and 20 different from values 21-65. This can be done by nesting
IF statements, as follows:
This formula works as follows:
Step 1: the first IF statement tests whether the value in cell A1 is greater than or equal to
Step 2: If the first IF statement is true (i.e., the value in cell A1 is greater than or equal to