formula

%3CLINGO-SUB%20id%3D%22lingo-sub-2265922%22%20slang%3D%22en-US%22%3Eformula%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2265922%22%20slang%3D%22en-US%22%3E%3CP%3Eneed%20formula%20for%26nbsp%3B%3C%2FP%3E%3CP%3Eb2-b3%3D%3C%2FP%3E%3CP%3Eif%20greater%20than%201%20return%200%3C%2FP%3E%3CP%3Eif%20%3D%20to%201%20return%201%3C%2FP%3E%3CP%3Eif%20%3D%20to%20o%20return%202%3C%2FP%3E%3CP%3Eif%20%3D%20to%20-1%20return%204%3C%2FP%3E%3CP%3Eif%20%3D%20to%20-2%20return%206%3C%2FP%3E%3CP%3Eif%20%3D%20to%20-3%20return%208%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-2265922%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EExcel%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2265952%22%20slang%3D%22en-US%22%3ERe%3A%20formula%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2265952%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F1022638%22%20target%3D%22_blank%22%3E%40scott4855%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThat%20could%20be%3A%3C%2FP%3E%3CPRE%20class%3D%22lia-code-sample%20language-applescript%22%3E%3CCODE%3E%3DLOOKUP(B5%2C%7B-3%3B-2%3B-1%3B0%3B1%3B2%7D%2C%7B8%3B6%3B4%3B2%3B1%3B0%7D)%3C%2FCODE%3E%3C%2FPRE%3E%3C%2FLINGO-BODY%3E
Occasional Visitor

need formula for 

b2-b3=

if greater than 1 return 0

if = to 1 return 1

if = to o return 2

if = to -1 return 4

if = to -2 return 6

if = to -3 return 8

1 Reply

@scott4855 

That could be:

=LOOKUP(B5,{-3;-2;-1;0;1;2},{8;6;4;2;1;0})