Array.elem(3kaya)

Array.elem3kaya

Check whether a value is in a list.

Usage

Bool elem( a val, [a] list, Bool(a, a) eq=equal )

Arguments

val The value to search for ("needle")

list The list to search ("haystack")

eq Optionally, the function used to check for presence (the default is Builtins.equal (3kaya) , obviously, but Builtins.identical (3kaya) might be used)

Overview

Check whether the "needle" occurs at least once in the "haystack". This function can be thought of as a specialised version of Array.any (3kaya)

Releases

4 releases since Debian 5.0 (Lenny); the text changed 3 times.

  1. 5.0
  2. 6.0
  3. 7
  4. 8

Authors

Kaya standard library by Edwin Brady, Chris Morris and others ([email protected]). For further information see http://kayalang.org/

License

The Kaya standard library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License (version 2.1 or any later version) as published by the Free Software Foundation.

From kaya 0.4.4-6.2 in Debian 8 (Jessie). Parsed by carta from the page's man source.