now counts the number of time if occurs