IFS function
IFS runs logical tests to check whether one or more conditions are met and returns a value that matches the first TRUE condition.
Syntax
IFS(test1, value_if_true1, [test2,
value_if_true2], [test3, value_if_true3],
…)
Note: You can test a maximum of 127 different conditions by IFS function.
- test1 is a condition that evaluates to TRUE or FALSE.
- value_if_true1 is the value to be returned if test1 evaluates to TRUE. It can be empty.
Example
=IFS(A1=1,"a",A1=2,"b",A1=3,"c")
If A1 equals 1, display a. If A1 equals 2, display b. If A1 equals 3, display c.