check works of count occurence