split counting + comments

Hi,  I added some descriptive comments to some lines I was having trouble with in the original code.

the splitcount/ code is all new