Computer Science, asked by ashishpar009, 8 months ago

4. State the use of IF function. Explain with an example.​

Answers

Answered by Anonymous
2

Use the IF function, one of the logical functions, to return one value if a condition is true and another value if it's false. For example: =IF(A2>B2,"Over Budget","OK")

Answered by Anonymous
2

Use:

This is a conditional function.

Condition always results in either True or False.

IF returns one value if a condition specified evaluates to TRUE and another if it evaluates to FALSE.

IF has to be used where conditional tests are to be conducted on values and formulae.

Syntax:

IF(Logical_Test or Condition, value_if_True,value_if_False)

Examples of if function

=IF(A1> 50, 150, 100) This means that if the value in cell A1 is greater than 50 then return value 150 otherwise returns value 100.

=IF(A2<=100,"Within Limits","Over Limits") This means that if the value in cell A2 is less than or equal to 100 then formula will display 'Within Limits' or else 'Over Limits' will be displayed.

Similar questions