Is there a better formula for adding every other cell

spectraflame

Well-known Member
Joined
Dec 18, 2002
Messages
830
Office Version
  1. 365
Platform
  1. Windows
I have a need to add every other cell in a row. The only way that I could think of was the following. Is there a better method?

=B7+D7+F7+H7+J7+L7+N7+P7+R7+T7+V7+X7+Z7+AB7+AD7+AF7+AH7+AJ7+AL7+AN7+AP7+AR7+AT7+AV7+AX7+AZ7+BB7+BD7+BF7+BH7+BJ7
 

Excel Facts

Remove leading & trailing spaces
Save as CSV to remove all leading and trailing spaces. It is faster than using TRIM().
The following array formula (confirmed using CTRL+SHIFT+ENTER, not just ENTER) should work:

=SUM(IF(MOD(COLUMN(A7:BJ7),2)=0,A7:BJ7))
 
Upvote 0
I have a need to add every other cell in a row. The only way that I could think of was the following. Is there a better method?

=B7+D7+F7+H7+J7+L7+N7+P7+R7+T7+V7+X7+Z7+AB7+AD7+AF7+
AH7+AJ7+AL7+AN7+AP7+AR7+AT7+AV7+AX7+AZ7+BB7+BD7+BF7+BH7+BJ7
Try this...

=SUMPRODUCT(--(MOD(COLUMN(B7:BJ7)-COLUMN(B7),2)=0),B7:BJ7)

This version is robust against new column insertions at the start of the range.

If the cells between the target cells DO NOT contain any numeric values then just a simple SUM formula will do:

=SUM(B7:BJ7)
 
Upvote 0

Forum statistics

Threads
1,224,503
Messages
6,179,135
Members
452,890
Latest member
Nikhil Ramesh

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