Ruby that checks to see if all elements in the array belong to the same class.