قالب وردپرس درنا توس
Home / Tips and Tricks / How to Use Logical Functions in Excel: IF, AND, OR, XOR, NOT

How to Use Logical Functions in Excel: IF, AND, OR, XOR, NOT



  Excel Logo

Logical functions are among the most popular and useful features in Excel. You can test values ​​in other cells and perform actions based on the test result. This helps us to automate tasks in our spreadsheets.

Using the IF function

The IF function is the most important logical function in Excel and therefore the first one to understand. It will appear several times in this article.

Let's take a look at the structure of the IF function and see some examples of its use.

The IF function accepts 3 bits of information:

  = IF (Logic_test, [value_if_true][value_if_false]) 
  • Logic_test: This is the condition for the function being tested.
  • value_if_true: The action to perform if the condition is true or true
  • value_if_false: The action to perform if the condition is not met or is false.

Relational operators for use with logical functions

When you perform the logical test on cell values, you must do so familiar with the comparison operators. For a breakdown of these, see the following table:

 Logical Function Relational Operators

Let's look at some examples of them in action.

IF Function Example 1: Text Values ​​

In this example we want to test if a cell matches a particular phrase. The IF function is case-insensitive, ignoring uppercase and lowercase letters.

Read the remaining 66 paragraphs


Source link