Try this.
its an array formula and I could have hardcoded the arrays into the formula but I've set it up in the attached spreadsheet to show how it might be easier to use.![]()
=SUMPRODUCT(C2:C5,IF(IF(E2-A2:A5>B2:B5-A2:A5,B2:B5-A2:A5,E2-A2:A5)<0,0,IF(E2-A2:A5>B2:B5-A2:A5,B2:B5-A2:A5,E2-A2:A5)))*E1
Can you check a few examples to make sure I've understood the logic and got the arithmetic right? thanks
And we won soccer too!
Bookmarks