instance method Enumerable#include
Enumerable#include(object) → Boolean
-
object
(?
) – The object to look for.
Determines whether a given object is in the enumerable or not,
based on the ==
comparison operator (equality with implicit type
conversion).
Examples
$R(1, 15).include(10);
// -> true
['hello', 'world'].include('HELLO');
// -> false ('hello' != 'HELLO')
[1, 2, '3', '4', '5'].include(3);
// -> true ('3' == 3)
Aliased as: Enumerable#member