Do you understand...
=if(LEFT(a2,5)=LEFT(b2,5),(if(LEFT(a3,5)=LEFT(b3,5),2,1),0)
Or...
SELECT County_Name, Count(Voters) FROM voters INNER JOIN ...