mirror of
https://github.com/ProgramSnail/Lama.git
synced 2025-12-06 06:48:48 +00:00
Added arrayFind
This commit is contained in:
parent
9e5c562d60
commit
11203f3a85
4 changed files with 16 additions and 1 deletions
|
|
@ -181,6 +181,10 @@ Array processing functions:
|
|||
\descr{\lstinline|fun iteriArray (f, a)|}{Applies a function "\lstinline|f|" to each element of an array "\lstinline|a|" and its index (index first);
|
||||
does not return a value.}
|
||||
|
||||
\descr{\lstinline|fun findArray (f, a)|}{Finds a value in an array "\lstinline|a|" which satisfies the predicate "\lstinline|f|". The
|
||||
predicate must return integer value, treated as boolean. Returns "\lstinline|None|" if no element satisfies "\lstinline|f|" and
|
||||
"\lstinline|Some (v)|" otherwise, where "\lstinline|v|"~--- the first value to satisfy "\lstinline|f|".}
|
||||
|
||||
\section{Unit \texttt{Collection}}
|
||||
\label{sec:collection}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue