IF with AND and OR

The OR function tells you if at least one of the input conditions is met. If one or more conditions are met, you get the output TRUE. If all conditions are not met, you get the output FALSE. For example, you can use the OR function to determine if a student passed at least one of their two courses.

The NOT function changes TRUE to FALSE or FALSE to TRUE. This is useful when you want to see when a condition is not met, or you want to perform an additional calculation. For example, you can use the NOT function to determine whether a student did not pass the final exam.

The AND, OR, and NOT functions are often used with the IF function to assess multiple conditions. We accomplish this by nesting functions. Nesting occurs when one function is placed as an argument in another function. For example, if a student's midterm grade is in C2 and the final grade is in F2, the following formula would determine whether the student passed both the midterm and final exams:
=IF(AND(C2>=60%,F2>=60%),"passed both midterm and final","did not pass both midterm and final")

In this example, we say the AND function is nested inside the IF function. Nesting adds another layer of complexity to formulas. Simple mistakes can generate errors or incorrect results. As you watch this tutorial, pay close attention to the proper syntax for each type of function.

 


Source: Renae K. Clark, https://www.youtube.com/watch?v=F30EeEWHIQo
Creative Commons License This work is licensed under a Creative Commons Attribution 3.0 License.

Last modified: Friday, July 5, 2024, 1:24 PM