简体   繁体   English

Excel公式,如果IF单元格编号“小于” X,“位于X和Y之间”或“大于” Y,则等于A,B,C

[英]Excel formula for IF cell number is 'lower' than X, 'in between' X and Y or 'higher' Y then equals A, B, C

I can get a simple IF formula working like: =IF(A3>100,"good","bad") 我可以得到一个简单的IF公式,如下所示: =IF(A3>100,"good","bad")

but what i would like is something that works for in between theses values too. 但是我想要的也是在这些值之间起作用的东西。

Example: 例:

A score of <80 = Bad , 80-100 = OK , >100 = Good Thanks. 分数<80 = Bad80-100 = OK>100 = Good

使用INDEX()

=INDEX({"Bad","OK","Good"},MATCH(A3,{-1E+99,80,100}))

You embed if statements: 您嵌入if语句:

=IF(A3>100,"good",IF(A3>80,"OK","bad"))

(not that if the maximum score is 100, then you should use: (不是,如果最高分是100,则应使用:

=IF(A3>=100,"good",IF(A3>80,"OK","bad"))

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM