def valid? *indexes
      indexes.all? { |i| to_a.include?(i) || (i.is_a?(Numeric) && i < size) }
    end
def valid? *indexes
      indexes.all? { |i| to_a.include?(i) || (i.is_a?(Numeric) && i < size) }
    end
Returns true if all arguments are either a valid category or position
 @param indexes [Array<object>] categories or positions
 @return [true, false]
 @example
   idx.valid? :a, 2
   # => true
   idx.valid? 3
   # => false