• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Problem with IF Formula

pradeepm

New Member
Please help me in the below formula.

=IF(A3>=1,"1",IF(B3>=1,"1",IF(A4>=1,"3",IF(B4>=2,"3",IF(A5>=1,"6",IF(B5>=3,"6",F(A6>=1,"10",IF(B6>=4,"10",IF(A7>=1,"15",IF(B7>=5,"15",IF(A8>=2,"2",IF(B8>=1,"2",IF(A9>=2,"5",IF(B9>=2,"5",IF(A10>=3,"13",IF(B10>=3,"13",IF(A11>=4,"21",IF(B11>=4,"21",IF(A12>=5,"25",IF(B12>=5,"25",IF(A13>=3,"22",IF(B13>=5,"22",IF(A14>=3,"8",IF(B14>=2,"8",IF(A15>=4,"12",IF(B15>=2,"12",IF(A16>=5,"16",IF(B16>=2,"16",IF(A17>=3,"4",IF(B17>=1,"4",IF(A18>=4,"7",IF(B18>=1,"7",IF(A19>=2,"9",IF(B19>=3,"9",IF(A20>=5,"11",IF(B20>=1,"11",IF(A21>=2,"14",IF(B21>=4,"14",IF(A22>=4,"17",IF(B22>=3,"17",IF(A23>=3,"18",IF(B23>=4,"18",IF(A24>=2,"19",IF(B24>=5,"19",IF(A25>=5,"20",IF(B25>=3,"20",IF(A26>=5,"23",IF(B26>=4,"23",IF(A27>=4,"24",IF(B27>=5,"24"))

I have two different figures in Column "A" and Column "B". I want to appy a IF formula in which the Result will be a different number mentioned in IF formula.

Attached Excel file with detail explanation.

Regards,
Pradeep
 

Attachments

  • IF Function Issue v1.xlsx
    18.3 KB · Views: 9
pradeepm
You've opened this thread to Excel Challenges.
Post an Excel related Challenge for others to Solve (You must have a solution) Don't post questions here!
This thread has move to Ask an Excel Questions.
 
Is there any sort of pattern or logic behind the results you want?
In words, what are you trying to do?
 
Hi pradeepm,

A lot of people want to help you, but no one understand what you want.

Please sit down and write to us " What are you trying to do and give us the expected result as well."

Have a nice day.

God blessings
God is so good to you.... giving you the gift.
 
Is there any sort of pattern or logic behind the results you want?
In words, what are you trying to do?
Hi pradeepm,

A lot of people want to help you, but no one understand what you want.

Please sit down and write to us " What are you trying to do and give us the expected result as well."

Have a nice day.

God blessings
God is so good to you.... giving you the gift.
Thank You very much for your reply sir,

My query is :
1) I have 2 columns A & B, Under A some figures are there under B some figures.
2) If Column A=1 & Column B=1 then Result should be 3
3) If Column A=3 and Column B=5 then Result should be 22.

Total 25 Results which based on Column A and B.
 
pradeepm
Please reread Forum Rules
especially part of How to get the Best Results at Chandoo.org
  • When drafting a question, try and lay out the question in a clear and concise way.
  • Try and tell the readers what is the situation, what have you tried and what do you want to achieve.
  • Don't leave out information more info is better
    Do those Your given results have any clear logic?
    What makes A=1 and B=1 combination 3?
    What would be correct expected result if A = 1 and B = 25?
    ... or are those always fixed?

  • Cross-Posting. Generally, it is considered poor practice to cross post. That is to post the same question on several forums in the hope of getting a response quicker.
    • If you do cross-post, please put that in your post.
    • Also if you have cross-posted and get an Solution elsewhere, have the courtesy of posting the Solution here so other readers can learn from the answer also, as well as stopping people wasting their time on your answered question.
 
Code:
=IFERROR(INDEX({1;3;6;10;15;2;5;13;21;25;22;8;12;16;4;7;9;11;14;17;18;19;20;23;24},MATCH(A3 & "¬" & B3,{"1¬1";"1¬2";"1¬3";"1¬4";"1¬5";"2¬1";"2¬2";"3¬3";"4¬4";"5¬5";"3¬5";"3¬2";"4¬2";"5¬2";"3¬1";"4¬1";"2¬3";"5¬1";"2¬4";"4¬3";"3¬4";"2¬5";"5¬3";"5¬4";"4¬5"},0)),"combination not found")
copied down
or in a single cell:
Code:
=IFERROR(INDEX({1;3;6;10;15;2;5;13;21;25;22;8;12;16;4;7;9;11;14;17;18;19;20;23;24},MATCH(A3:A27 & "¬" & B3:B27,{"1¬1";"1¬2";"1¬3";"1¬4";"1¬5";"2¬1";"2¬2";"3¬3";"4¬4";"5¬5";"3¬5";"3¬2";"4¬2";"5¬2";"3¬1";"4¬1";"2¬3";"5¬1";"2¬4";"4¬3";"3¬4";"2¬5";"5¬3";"5¬4";"4¬5"},0)),"combination not found")
 
pradeepm
Please reread Forum Rules
especially part of How to get the Best Results at Chandoo.org
  • When drafting a question, try and lay out the question in a clear and concise way.
  • Try and tell the readers what is the situation, what have you tried and what do you want to achieve.
  • Don't leave out information more info is better
    Do those Your given results have any clear logic?
    What makes A=1 and B=1 combination 3?
    What would be correct expected result if A = 1 and B = 25?
    ... or are those always fixed?

  • Cross-Posting. Generally, it is considered poor practice to cross post. That is to post the same question on several forums in the hope of getting a response quicker.
    • If you do cross-post, please put that in your post.
    • Also if you have cross-posted and get an Solution elsewhere, have the courtesy of posting the Solution here so other readers can learn from the answer also, as well as stopping people wasting their time on your answered question.
Dear Sir,
Thank you for your Valuable suggestion.
I got the answer for the same question and got my answer. Her is the Formula for my question.
=IF(E2>=5,IF(F2>=5,25,IF(F2>=4,23,IF(F2>=3,20,IF(F2>=2,16,11)))), IF(E2>=4,IF(F2>=5,24,IF(F2>=4,21,IF(F2>=3,17,IF(F2>=2,12,7)))), IF(E2>=3,IF(F2>=5,22,IF(F2>=4,18,IF(F2>=3,13,IF(F2>=2,8,4)))), IF(E2>=2,IF(F2>=5,19,IF(F2>=4,14,IF(F2>=3,9,IF(F2>=2,5,2)))), IF(E2>=1,IF(F2>=5,15,IF(F2>=4,10,IF(F2>=3,6,IF(F2>=2,3,1)))))))))

I do have courtesy to post/reply but due to busy work schedule, i dnt..
 
pradeepm
Please, before You'll open a new thread, reread Forum Rules.
If You decide to Cross-post Your questions then You'll know what to do.
Others could help You smoother, if You could able to answer their questions too; I didn't get.
Case busy ... then You should try to start earlier.
 
Dear Sir,
Thank you for your Valuable suggestion.
I got the answer for the same question and got my answer. Her is the Formula for my question.
=IF(E2>=5,IF(F2>=5,25,IF(F2>=4,23,IF(F2>=3,20,IF(F2>=2,16,11)))), IF(E2>=4,IF(F2>=5,24,IF(F2>=4,21,IF(F2>=3,17,IF(F2>=2,12,7)))), IF(E2>=3,IF(F2>=5,22,IF(F2>=4,18,IF(F2>=3,13,IF(F2>=2,8,4)))), IF(E2>=2,IF(F2>=5,19,IF(F2>=4,14,IF(F2>=3,9,IF(F2>=2,5,2)))), IF(E2>=1,IF(F2>=5,15,IF(F2>=4,10,IF(F2>=3,6,IF(F2>=2,3,1)))))))))

I do have courtesy to post/reply but due to busy work schedule, i dnt..
Happy to hear that you can do it by your own self,

Then, you can dig deeper to understand more about the IF function.

Let us Excelling to further study of the Excel other functions.

God blessings
God is so good to you.... giving you the gift.
 
Last edited:
pradeepm
Instead of using some IF
... You could use something like this sample.
This C-column version has used once IF.
Of course, there will be basic sample formula-solution too in D-column.
 

Attachments

  • IF Function Issue v1.xlsb
    24.9 KB · Views: 2
Last edited:
Back
Top