(has? coll key) coll: any type key: any type returns a bool
F
Returns #t
if a collection contains a particular item.
coll
may belong to any type, but if it's something other than an array, string, table,
object, class or rdata, this function always returns #f
.
(prn (has? '(a b c) -1)) ; prints #t
(prn (has? '(a b c) 4)) ; prints #f
(prn (has? '(a b c) 'key)) ; prints #f
(prn (has? 'symbol 2)) ; prints #f