Ads 468x60px

Saturday, October 13, 2012

Write a formula to check few cells have same value [homework]

Write a formula to check few cells have same value [homework]:
Lets test your Excel skills. Can you write a formula to check few cells are equal?

Your homework:

  • Let us say you have four values in cells A1, A2, A3, A4
  • Write a formula to check if all 4 cells have same value (ie A1=A2=A3=A4)
  • Your output can be TRUE/FALSE or 1/0 to indicate a match (or mis-match)
Bonus question 1:
How would you write a formula if your values are in range A1:An
Bonus question 2:
What formula would work well if the cells contain non-numeric values (text, logical etc.)

Obvious answer:

The easiest and obvious answer is to test if all them are equal. The formula is,
=AND(A1=A2,A1=A3,A1=A4)
(select the above blank line to see answer)
But can you come up with some other options to test the equality?
Click here to post your answer.
Want more Excel home works, quizzes & challenges?

0 comments:

Post a Comment