PERF: Use python integer on _count_reduce_items (#21465)
PERF: Use python integer on _count_reduce_items (#21465)

Small micro-optimization, since using Python integers is generally a bit faster in the loop.
The effect is small, so this could undone if anyone figures it is cleaner the other way.
charris/numpy,mhvk/numpy,pdebuyl/numpy,endolith/numpy,mattip/numpy,mattip/numpy,numpy/numpy,charris/numpy,mhvk/numpy,pdebuyl/numpy,mattip/numpy,anntzer/numpy,numpy/numpy,anntzer/numpy,mattip/numpy,mhvk/numpy,anntzer/numpy,numpy/numpy,jakirkham/numpy,jakirkham/numpy,jakirkham/numpy,pdebuyl/numpy,mhvk/numpy,endolith/numpy,numpy/numpy,endolith/numpy,rgommers/numpy,mhvk/numpy,jakirkham/numpy,pdebuyl/numpy,charris/numpy,rgommers/numpy,rgommers/numpy,endolith/numpy,jakirkham/numpy,rgommers/numpy,anntzer/numpy,charris/numpy