method

without

Importance_1
v5.0.0.1 - Show latest stable - 0 notes - Class: Array
without(*elements) public

Returns a copy of the Array without the specified elements.

people = ["David", "Rafael", "Aaron", "Todd"]
people.without "Aaron", "Todd"
  => ["David", "Rafael"]

Note: This is an optimization of `Enumerable#without` that uses `Array#-` instead of `Array#reject` for performance reasons.

Show source
Register or log in to add new notes.