Excel IF formula

%3CLINGO-SUB%20id%3D%22lingo-sub-3088089%22%20slang%3D%22en-US%22%3EExcel%20IF%20formula%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-3088089%22%20slang%3D%22en-US%22%3EHi%20!%3CBR%20%2F%3EI%20want%20to%20create%20an%20IF%20formula%20that%20if%20it%20was%20%22good%22%20gives%2052%3CBR%20%2F%3EAnd%20if%20it%20was%20%22bad%22%20gives%2060%3CBR%20%2F%3EHow%20to%20do%20it%20%3F%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-3088089%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EFormulas%20and%20Functions%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-3088165%22%20slang%3D%22en-US%22%3ERe%3A%20Excel%20IF%20formula%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-3088165%22%20slang%3D%22en-US%22%3EHello%20Mohammed%2C%3CBR%20%2F%3EI%20will%20assume%20that%20your%20data%20is%20on%20A1%2C%20try%20this%20formula%3CBR%20%2F%3E%3DIF(A1%3D%22good%22%2C52%2CIF(A1%3D%22bad%22%2C60%2C))%3C%2FLINGO-BODY%3E
Occasional Visitor
Hi !
I want to create an IF formula that if it was "good" gives 52
And if it was "bad" gives 60
How to do it ?
2 Replies
Hello Mohammed,
I will assume that your data is on A1, try this formula
=IF(A1="good",52,IF(A1="bad",60,))

@Mohammed675 

As variant

=(A1="good")*52 + (A1="bad")*60