C Program to count the Array Elements