Count String Functions In Python Class