Compare two cells, greater or less than by 2 or more

dandanfielding

New Member
Joined
Apr 1, 2023
Messages
5
Office Version
  1. 2010
Platform
  1. Windows
I'm looking to write a formula comparing two cells. If the second cell is greater or less than the first cell by 2 or more, I need to increment or decrement the value in the first cell by 1 for every 2 points of difference. I'm kind of stumped. I've tried nested IF statements, so far with no luck.
 

Excel Facts

Did you know Excel offers Filter by Selection?
Add the AutoFilter icon to the Quick Access Toolbar. Select a cell containing Apple, click AutoFilter, and you will get all rows with Apple
try this:

mr excel questions 21.xlsm
ABC
1Value1Value2NewValue
2111
3121
4132
5212
6222
7232
8243
9253
10264
dandanfielding
Cell Formulas
RangeFormula
C2:C10C2=IF(A2+2<=B2,A2+ROUNDDOWN((B2-A2)/2,0),A2)
 
Upvote 0
Solution
My pleasure. And welcome to the forum.

If you think a post here has provided you with a solution, please mark it as the answer.

Best wishes.
 
Upvote 0
My pleasure. And welcome to the forum.

If you think a post here has provided you with a solution, please mark it as the answer.

Best wishes.
Thanks for the warm welcome! I didn't notice an option to mark a reply as the solution, but after your reply I found it and have done so.
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,181
Members
453,022
Latest member
Mohamed Magdi Tawfiq Emam

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top