state count stuff