added function to count strings in array