elem package:rio

O(n) elem is the ByteString membership predicate.
Does the element occur in the structure?
O(n) Check if the vector contains an element
O(n) Check if the vector contains an element
O(n) Check if the vector contains an element
O(n) Check if the vector contains an element
O(n) The elemIndex function returns the index of the first element in the given ByteString which is equal to the query element, or Nothing if there is no such element. This implementation uses memchr(3).
O(n) The elemIndexEnd function returns the last index of the element in the given ByteString which is equal to the query element, or Nothing if there is no such element. The following holds:
elemIndexEnd c xs ==
(-) (length xs - 1) `fmap` elemIndex c (reverse xs)
O(n) The elemIndices function extends elemIndex, by returning the indices of all elements equal to the query element, in ascending order. This implementation uses memchr(3).
O(n) The elemIndex function returns the index of the first element in the given ByteString which is equal to the query element, or Nothing if there is no such element. This implementation uses memchr(3).
O(n) The elemIndexEnd function returns the last index of the element in the given ByteString which is equal to the query element, or Nothing if there is no such element. The following holds:
elemIndexEnd c xs ==
(-) (length xs - 1) `fmap` elemIndex c (reverse xs)
O(n) The elemIndices function extends elemIndex, by returning the indices of all elements equal to the query element, in ascending order. This implementation uses memchr(3).
Return a list of this map's values. The list is produced lazily.
The elemIndex function returns the index of the first element in the given list which is equal (by ==) to the query element, or Nothing if there is no such element.
>>> elemIndex 4 [0..]
Just 4
The elemIndices function extends elemIndex, by returning the indices of all elements equal to the query element, in ascending order.
>>> elemIndices 'o' "Hello World"
[4,7]
O(log n). Retrieve an element by its index, i.e. by its zero-based index in the sequence sorted by keys. If the index is out of range (less than zero, greater or equal to size of the map), error is called.
elemAt 0 (fromList [(5,"a"), (3,"b")]) == (3,"b")
elemAt 1 (fromList [(5,"a"), (3,"b")]) == (5, "a")
elemAt 2 (fromList [(5,"a"), (3,"b")])    Error: index out of range
O(n). Return all elements of the map in the ascending order of their keys. Subject to list fusion.
elems (fromList [(5,"a"), (3,"b")]) == ["b","a"]
elems empty == []
elemIndexL finds the leftmost index of the specified element, if it is present, and otherwise Nothing.
elemIndexR finds the rightmost index of the specified element, if it is present, and otherwise Nothing.
elemIndicesL finds the indices of the specified element, from left to right (i.e. in ascending order).
elemIndicesR finds the indices of the specified element, from right to left (i.e. in descending order).
O(n). An alias of toAscList. The elements of a set in ascending order. Subject to list fusion.
O(log n). Retrieve an element by its index, i.e. by its zero-based index in the sorted sequence of elements. If the index is out of range (less than zero, greater or equal to size of the set), error is called.
elemAt 0 (fromList [5,3]) == 3
elemAt 1 (fromList [5,3]) == 5
elemAt 2 (fromList [5,3])    Error: index out of range
O(n) Yield Just the index of the first occurence of the given element or Nothing if the vector does not contain the element. This is a specialised version of findIndex.
O(n) Yield the indices of all occurences of the given element in ascending order. This is a specialised version of findIndices.