Reputation: 11
I have to define a range numbers to a rating and the rating is just one letter and based on the range of numbers the next cell should show the letter.
Example:
10231 = A
8034 = B
6433 = C
4542 = D
1323 = F
If I enter number in A1 cell as 3214, in B1 cell I should get F Can we do this with simple formula? Or does this require VB?
Upvotes: 1
Views: 2797
Reputation: 55692
Played a little to see if I could shorten it using the repetitive patterns.
The VLOOKUP is easier to understand
=CHOOSE(MAX(INT(A1/2000),1),"F","D","C","B","A")
Upvotes: 0
Reputation: 23994
Try this formula in B1:
=VLOOKUP(A1,{0,"F";4000,"D";6000,"C";8000,"B";10000,"A"},2,TRUE)
Upvotes: 5