Counting Even-Odd second digit from the right

Mike7

Board Regular
Joined
Dec 27, 2002
Messages
98
HI,
I have 10 numbers in the range A1:J1
345 687 23 1790 717 546 2581 74 522 841

and formulas that count odd and even numbers in that range

=SUMPRODUCT(--(MOD(A1:J1,2)=1)) with result 6
=SUMPRODUCT(--(MOD(A1:J1,2)<>1)) with result 4

I need a formula which does the same, but only for second digits from the right.
Expected results: 3 odd , 7 even.

Thanks
 

Excel Facts

How to calculate loan payments in Excel?
Use the PMT function: =PMT(5%/12,60,-25000) is for a $25,000 loan, 5% annual interest, 60 month loan.
Perhaps the formulas in C5:C6 here:
Book1
ABCDEFGHIJ
1345687231790717546258174522841
2
3
4
56Odd3
64Even7
Sheet2
Cell Formulas
RangeFormula
A5A5=SUMPRODUCT(--(MOD(A1:J1,2)=1))
A6A6=SUMPRODUCT(--(MOD(A1:J1,2)<>1))
C5C5=SUMPRODUCT(--(MOD(MID(A1:J1,LEN(A1:J1)-1,1),2)=1))
C6C6=SUMPRODUCT(--(MOD(MID(A1:J1,LEN(A1:J1)-1,1),2)<>1))
 
Upvote 0
What version of Excel are you using?
I suggest that you update your Account details (or click your user name at the top right of the forum) so helpers always know what Excel version(s) & platform(s) you are using as the best solution often varies by version. (Don’t forget to scroll down & ‘Save’)
 
Upvote 0
=SUMPRODUCT(--(MOD(INT(A1:J1/10),2)=1))
=SUMPRODUCT(--(MOD(INT(A1:J1/10),2)=0))
 
Last edited:
Upvote 0

Forum statistics

Threads
1,223,903
Messages
6,175,284
Members
452,630
Latest member
OdubiYouth

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