SOLVED

If Then statement with ranged values

%3CLINGO-SUB%20id%3D%22lingo-sub-2526920%22%20slang%3D%22en-US%22%3EIf%20Then%20statement%20with%20ranged%20values%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2526920%22%20slang%3D%22en-US%22%3E%3CP%3EHi!%20I%20am%20trying%20to%20construct%20a%20basic%20If%20Then%20statement%20in%20Excel%20where%20I%20would%20like%20a%20cell%20to%20output%20either%20%22Few%22%2C%20%22Some%22%2C%20or%20%22Many%22%20based%20on%20the%20value%20of%20another%20cell.%20It%20is%20simple%20to%20do%20such%20a%20statement%20with%20two%20outputs...%20e.g.%2C%26nbsp%3B%3DIF(E26%26lt%3B8%2C%22Few%22%2C%22Many%22)%2C%20where%20if%20the%20value%20in%20E26%20is%20less%20than%208%2C%20my%20cell%20will%20output%20%22Few%22%20and%20if%20it%20is%20greater%2C%20it%20will%20output%20%22Many%22.%20A%20note%20that%20might%20be%20pertinent%20is%20that%20E26%20is%20itself%20the%20product%20of%20a%20SUM%20formula.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EBut%2C%20if%20I%20wanted%20%22Few%22%20to%20correspond%20to%20%26lt%3B8%2C%20%22Some%22%20to%20correspond%20to%208-14%2C%20and%20%22Many%22%20to%20correspond%20to%20%26gt%3B14...%20what%20would%20I%20write%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThanks!%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-2526920%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EExcel%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EFormulas%20and%20Functions%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2527008%22%20slang%3D%22en-US%22%3ERe%3A%20If%20Then%20statement%20with%20ranged%20values%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2527008%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F1098370%22%20target%3D%22_blank%22%3E%40Noths760%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3EPlease%20try%20this...%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CPRE%20class%3D%22lia-code-sample%20language-applescript%22%3E%3CCODE%3E%3DIF(E26%26lt%3B8%2C%22Few%22%2CIF(E26%26lt%3B%3D14%2C%22Some%22%2C%22Many%22))%3C%2FCODE%3E%3C%2FPRE%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2527056%22%20slang%3D%22en-US%22%3ERe%3A%20If%20Then%20statement%20with%20ranged%20values%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2527056%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F1098370%22%20target%3D%22_blank%22%3E%40Noths760%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3EAlternatively%2C%20if%20you%20run%20Excel%202019%20or%20365%3A%3C%2FP%3E%3CPRE%20class%3D%22lia-code-sample%20language-excel%22%3E%3CCODE%3E%3DIFS(E26%20%26lt%3B%208%2C%22Few%22%2C%20E26%20%26lt%3B%3D%2014%2C%22Some%22%2C%20TRUE%2C%22Many%22)%3C%2FCODE%3E%3C%2FPRE%3E%3C%2FLINGO-BODY%3E
Occasional Contributor

Hi! I am trying to construct a basic If Then statement in Excel where I would like a cell to output either "Few", "Some", or "Many" based on the value of another cell. It is simple to do such a statement with two outputs... e.g., =IF(E26<8,"Few","Many"), where if the value in E26 is less than 8, my cell will output "Few" and if it is greater, it will output "Many". A note that might be pertinent is that E26 is itself the product of a SUM formula.

 

But, if I wanted "Few" to correspond to <8, "Some" to correspond to 8-14, and "Many" to correspond to >14... what would I write?

 

Thanks!

4 Replies
best response confirmed by Noths760 (Occasional Contributor)
Solution

@Noths760 

Please try this...

 

=IF(E26<8,"Few",IF(E26<=14,"Some","Many"))

@Noths760 

Alternatively, if you run Excel 2019 or 365:

=IFS(E26 < 8,"Few", E26 <= 14,"Some", TRUE,"Many")
Great! Thank you - this worked nicely.

You're welcome @Noths760! Glad it worked as desired.

 

Please take a minute to accept the post with the proposed Solution as a Best Response to mark your question as Solved.