csharpfftfsharpintegrationinterpolationlinear-algebramathdifferentiationmatrixnumericsrandomregressionstatisticsmathnet
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
325 lines
30 KiB
325 lines
30 KiB
<HTML><HEAD><TITLE>Microsoft.FSharp.Collections.Array</TITLE><link rel="stylesheet" type="text/css"href="../msdn.css"></link></HEAD><BODY>
|
|
<br><dl>
|
|
<dt></dt><dd>
|
|
<h1>[<a href='../namespaces.html'>Home</a>] Module <a href='Microsoft.FSharp.Collections.html'>Microsoft.FSharp.Collections</a>.Array </h1><br>
|
|
</dd>
|
|
<dt></dt><dd>
|
|
<table>
|
|
<tr valign='top'><td><summary>
|
|
Basic operations on arrays
|
|
</summary>
|
|
<dt><h3>Values</h3></dt><dd>
|
|
<table width="100%%">
|
|
<tr><th width=60%>Value</th><th>Description</th></tr>
|
|
<tr valign="top"><td><pre>val append : 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Build a new array that contains the elements of the first array followed by the elements of the second array
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val average : overloaded</pre></td><td><summary>
|
|
Return the average of the elements in the array. If the array is empty an ArgumentException is thrown.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val averageBy : overloaded</pre></td><td><summary>
|
|
Return the average of the elements generated by applying the function to each element of the array.
|
|
If the array is empty an ArgumentException is thrown.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val blit : 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__int.html'>int</a> -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__int.html'>int</a> -> <a href='Microsoft.FSharp.Core.type__int.html'>int</a> -> <a href='Microsoft.FSharp.Core.type__unit.html'>unit</a></pre></td><td><summary>
|
|
Read a range of elements from the first array and write them into the second.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val choose : ('T -> 'U <a href='Microsoft.FSharp.Core.type__option-1.html'>option</a>) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'U <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Apply the given function to each element of the array. Return
|
|
the array comprised of the results "x" for each element where
|
|
the function returns Some(x)
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val collect : ('T -> 'U <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a>) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'U <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
For each element of the array, apply the given function. Concatenate all the results and return the combined array.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>[<<a href='Microsoft.FSharp.Core.type_OCamlCompatibilityAttribute.html'>OCamlCompatibilityAttribute</a>
|
|
("This F# library function has been renamed. Use 'zip' instead")>]
|
|
val combine : 'T1 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T2 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> ('T1 * 'T2) <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td></td></tr>
|
|
<tr valign="top"><td><pre>val concat : <a href='Microsoft.FSharp.Collections.type__seq-1.html'>seq</a><'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a>> -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Build a new array that contains the elements of each of the given sequence of arrays
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val copy : 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Build a new array that contains the elements of the given array
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val create : <a href='Microsoft.FSharp.Core.type__int.html'>int</a> -> 'T -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Create an array whose elements are all initially the given value.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>[<<a href='Microsoft.FSharp.Core.type_GeneralizableValueAttribute.html'>GeneralizableValueAttribute</a> ()>]
|
|
val empty<'T> : 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Return an empty array of the given type
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val exists : ('T -> <a href='Microsoft.FSharp.Core.type__bool.html'>bool</a>) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__bool.html'>bool</a></pre></td><td><summary>
|
|
Test if any element of the array satisfies the given predicate.
|
|
|
|
The predicate is applied to the elements of the input array. If any application
|
|
returns true then the overall result is true and no further elements are tested.
|
|
Otherwise, false is returned.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val exists2 : ('T1 -> 'T2 -> <a href='Microsoft.FSharp.Core.type__bool.html'>bool</a>) -> 'T1 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T2 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__bool.html'>bool</a></pre></td><td><summary>
|
|
Test if any pair of corresponding elements of the arrays satisfies the given predicate.
|
|
|
|
The predicate is applied to matching elements in the two collections up to the lesser of the
|
|
two lengths of the collections. If any application returns true then the overall result is
|
|
true and no further elements are tested. Otherwise, if one collections is longer
|
|
than the other then the <tt>ArgumentException</tt> exception is raised.
|
|
Otherwise, false is returned.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val fill : 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__int.html'>int</a> -> <a href='Microsoft.FSharp.Core.type__int.html'>int</a> -> 'T -> <a href='Microsoft.FSharp.Core.type__unit.html'>unit</a></pre></td><td><summary>
|
|
Fill a range of elements of the array with the given value.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val filter : ('T -> <a href='Microsoft.FSharp.Core.type__bool.html'>bool</a>) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Return a new collection containing only the elements of the collection
|
|
for which the given predicate returns "true"
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val find : ('T -> <a href='Microsoft.FSharp.Core.type__bool.html'>bool</a>) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T</pre></td><td><summary>
|
|
Return the first element for which the given function returns 'true'.
|
|
Raise <tt>KeyNotFoundException</tt> if no such element exists.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val findIndex : ('T -> <a href='Microsoft.FSharp.Core.type__bool.html'>bool</a>) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__int.html'>int</a></pre></td><td><summary>
|
|
Return the index of the first element in the array
|
|
that satisfies the given predicate. Raise <tt>KeyNotFoundException</tt> if
|
|
none of the elements satisy the predicate.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val fold : ('State -> 'T -> 'State) -> 'State -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'State</pre></td><td><summary>
|
|
Apply a function to each element of the collection, threading an accumulator argument
|
|
through the computation. If the input function is <tt>f</tt> and the elements are <tt>i0...iN</tt> then computes
|
|
<tt>f (... (f s i0)...) iN</tt>
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val fold2 :
|
|
('State -> 'T1 -> 'T2 -> 'State) -> 'State -> 'T1 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T2 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'State</pre></td><td><summary>
|
|
Apply a function to pairs of elements drawn from the two collections,
|
|
left-to-right, threading an accumulator argument
|
|
through the computation. The two input
|
|
arrays must have the same lengths, otherwise an <tt>ArgumentException</tt> is
|
|
raised.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>[<<a href='Microsoft.FSharp.Core.type_OCamlCompatibilityAttribute.html'>OCamlCompatibilityAttribute</a>
|
|
("This F# library function has been renamed. Use 'fold' instead")>]
|
|
val fold_left : ('State -> 'T -> 'State) -> 'State -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'State</pre></td><td></td></tr>
|
|
<tr valign="top"><td><pre>[<<a href='Microsoft.FSharp.Core.type_OCamlCompatibilityAttribute.html'>OCamlCompatibilityAttribute</a>
|
|
("This F# library function has been renamed. Use 'foldBack' instead")>]
|
|
val fold_right : ('T -> 'State -> 'State) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'State -> 'State</pre></td><td><summary>
|
|
Apply a function to each element of the array, threading an accumulator argument
|
|
through the computation. If the input function is <tt>f</tt> and the elements are <tt>i0...iN</tt>
|
|
then computes <tt>f i0 (...(f iN s))</tt>
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val foldBack : ('T -> 'State -> 'State) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'State -> 'State</pre></td><td><summary>
|
|
Apply a function to each element of the array, threading an accumulator argument
|
|
through the computation. If the input function is <tt>f</tt> and the elements are <tt>i0...iN</tt> then computes
|
|
<tt>f i0 (...(f iN s))</tt>
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val foldBack2 :
|
|
('T1 -> 'T2 -> 'State -> 'State) -> 'T1 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T2 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'State -> 'State</pre></td><td><summary>
|
|
Apply a function to pairs of elements drawn from the two collections, right-to-left,
|
|
threading an accumulator argument through the computation. The two input
|
|
arrays must have the same lengths, otherwise an <tt>ArgumentException</tt> is
|
|
raised.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>[<<a href='Microsoft.FSharp.Core.type_OCamlCompatibilityAttribute.html'>OCamlCompatibilityAttribute</a>
|
|
("This F# library function has been renamed. Use 'forall' instead")>]
|
|
val for_all : ('T -> <a href='Microsoft.FSharp.Core.type__bool.html'>bool</a>) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__bool.html'>bool</a></pre></td><td></td></tr>
|
|
<tr valign="top"><td><pre>val forall : ('T -> <a href='Microsoft.FSharp.Core.type__bool.html'>bool</a>) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__bool.html'>bool</a></pre></td><td><summary>
|
|
Test if all elements of the array satisfy the given predicate.
|
|
|
|
The predicate is applied to the elements of the input collection. If any application
|
|
returns false then the overall result is false and no further elements are tested.
|
|
Otherwise, true is returned.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val forall2 : ('T1 -> 'T2 -> <a href='Microsoft.FSharp.Core.type__bool.html'>bool</a>) -> 'T1 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T2 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__bool.html'>bool</a></pre></td><td><summary>
|
|
Test if all corresponding elements of the array satisfy the given predicate pairwise.
|
|
|
|
The predicate is applied to matching elements in the two collections up to the lesser of the
|
|
two lengths of the collections. If any application returns false then the overall result is
|
|
false and no further elements are tested. Otherwise, if one collection is longer
|
|
than the other then the <tt>ArgumentException</tt> exception is raised.
|
|
Otherwise, true is returned.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val get : 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__int.html'>int</a> -> 'T</pre></td><td><summary>
|
|
Get an element from an array
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val init : <a href='Microsoft.FSharp.Core.type__int.html'>int</a> -> (<a href='Microsoft.FSharp.Core.type__int.html'>int</a> -> 'T) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Create an array given the dimension and a generator function to compute the elements.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val isEmpty : 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__bool.html'>bool</a></pre></td><td><summary>
|
|
Return true if the given array is empty, otherwise false
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val iter : ('T -> <a href='Microsoft.FSharp.Core.type__unit.html'>unit</a>) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__unit.html'>unit</a></pre></td><td><summary>
|
|
Apply the given function to each element of the array.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val iter2 : ('T1 -> 'T2 -> <a href='Microsoft.FSharp.Core.type__unit.html'>unit</a>) -> 'T1 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T2 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__unit.html'>unit</a></pre></td><td><summary>
|
|
Apply the given function to pair of elements drawn from matching indices in two arrays. The
|
|
two arrays must have the same lengths, otherwise an <tt>ArgumentException</tt> is
|
|
raised.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val iteri : (<a href='Microsoft.FSharp.Core.type__int.html'>int</a> -> 'T -> <a href='Microsoft.FSharp.Core.type__unit.html'>unit</a>) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__unit.html'>unit</a></pre></td><td><summary>
|
|
Apply the given function to each element of the array. The integer passed to the
|
|
function indicates the index of element.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val iteri2 : (<a href='Microsoft.FSharp.Core.type__int.html'>int</a> -> 'T1 -> 'T2 -> <a href='Microsoft.FSharp.Core.type__unit.html'>unit</a>) -> 'T1 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T2 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__unit.html'>unit</a></pre></td><td><summary>
|
|
Apply the given function to pair of elements drawn from matching indices in two arrays,
|
|
also passing the index of the elements. The two arrays must have the same lengths,
|
|
otherwise an <tt>ArgumentException</tt> is raised.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val length : 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__int.html'>int</a></pre></td><td><summary>
|
|
Return the length of an array. You can also use property arr.Length.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>[<<a href='Microsoft.FSharp.Core.type_OCamlCompatibilityAttribute.html'>OCamlCompatibilityAttribute</a>
|
|
("This F# library function has been renamed. Use 'create' instead")>]
|
|
val make : <a href='Microsoft.FSharp.Core.type__int.html'>int</a> -> 'T -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td></td></tr>
|
|
<tr valign="top"><td><pre>val map : ('T -> 'U) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'U <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Build a new array whose elements are the results of applying the given function
|
|
to each of the elements of the array.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val map2 : ('T1 -> 'T2 -> 'U) -> 'T1 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T2 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'U <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Build a new collection whose elements are the results of applying the given function
|
|
to the corresponding elements of the two collections pairwise. The two input
|
|
arrays must have the same lengths, otherwise an <tt>ArgumentException</tt> is
|
|
raised.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val mapi : (<a href='Microsoft.FSharp.Core.type__int.html'>int</a> -> 'T -> 'U) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'U <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Build a new array whose elements are the results of applying the given function
|
|
to each of the elements of the array. The integer index passed to the
|
|
function indicates the index of element being transformed.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val mapi2 : (<a href='Microsoft.FSharp.Core.type__int.html'>int</a> -> 'T1 -> 'T2 -> 'U) -> 'T1 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T2 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'U <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Build a new collection whose elements are the results of applying the given function
|
|
to the corresponding elements of the two collections pairwise, also passing the index of
|
|
the elements. The two input arrays must have the same lengths, otherwise an <tt>ArgumentException</tt> is
|
|
raised.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val max : 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T</pre></td><td><summary>
|
|
Return the greatest of all elements of the array, compared via Operators.max on the function result
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val maxBy : ('T -> 'U) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T</pre></td><td><summary>
|
|
Return the greatest of all elements of the array, compared via Operators.max on the function result
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val min : 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T</pre></td><td><summary>
|
|
Return the lowest of all elements of the array, compared via Operators.min
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val minBy : ('T -> 'U) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T</pre></td><td><summary>
|
|
Return the lowest of all elements of the array, compared via Operators.min on the function result
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val of_list : 'T <a href='Microsoft.FSharp.Collections.type__list-1.html'>list</a> -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Build an array from the given list
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val of_seq : <a href='Microsoft.FSharp.Collections.type__seq-1.html'>seq</a><'T> -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Build a new array from the given enumerable object
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val partition : ('T -> <a href='Microsoft.FSharp.Core.type__bool.html'>bool</a>) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> * 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Split the collection into two collections, containing the
|
|
elements for which the given predicate returns "true" and "false"
|
|
respectively
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val permute : (<a href='Microsoft.FSharp.Core.type__int.html'>int</a> -> <a href='Microsoft.FSharp.Core.type__int.html'>int</a>) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Returns an array with all elements permuted according to the
|
|
specified permutation
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val pick : ('T -> 'U <a href='Microsoft.FSharp.Core.type__option-1.html'>option</a>) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'U</pre></td><td><summary>
|
|
Apply the given function to successive elements, returning the first
|
|
result where function returns <tt>Some(x)</tt> for some <tt>x</tt>. If the function
|
|
never returns <tt>Some(x)</tt> then <tt>KeyNotFoundException</tt> is raised.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val reduce : ('T -> 'T -> 'T) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T</pre></td><td><summary>
|
|
Apply a function to each element of the array, threading an accumulator argument
|
|
through the computation. If the input function is <tt>f</tt> and the elements are <tt>i0...iN</tt>
|
|
then computes <tt>f (... (f i0 i1)...) iN</tt>.
|
|
Raises ArgumentException if the array has size zero.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val reduceBack : ('T -> 'T -> 'T) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T</pre></td><td><summary>
|
|
Apply a function to each element of the array, threading an accumulator argument
|
|
through the computation. If the input function is <tt>f</tt> and the elements are <tt>i0...iN</tt>
|
|
then computes <tt>f i0 (...(f iN-1 iN))</tt>.
|
|
Raises ArgumentException if the array has size zero.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val rev : 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Return a new array with the elements in reverse order
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val scan : ('State -> 'T -> 'State) -> 'State -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'State <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Like <tt>fold_left</tt>, but return the intermediary and final results
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val scanBack : ('T -> 'State -> 'State) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'State -> 'State <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Like <tt>fold_right</tt>, but return both the intermediary and final results
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val set : 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__int.html'>int</a> -> 'T -> <a href='Microsoft.FSharp.Core.type__unit.html'>unit</a></pre></td><td><summary>
|
|
Set an element of an array
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val sort : 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Sort the elements of an array, returning a new array. Elements are compared using Operators.compare.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val sortBy : ('T -> 'U) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Sort the elements of an array, using the given projection for the keys and returning a new array. Elements are compared using Operators.compare.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val sortInPlace : 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__unit.html'>unit</a></pre></td><td><summary>
|
|
Sort the elements of an array by mutating the array in-place, using the given comparison function. Elements are compared using Operators.compare.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val sortInPlaceBy : ('T -> 'U) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__unit.html'>unit</a></pre></td><td><summary>
|
|
Sort the elements of an array by mutating the array in-place, using the given projection for the keys. Elements are compared using Operators.compare.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val sortInPlaceWith : ('T -> 'T -> <a href='Microsoft.FSharp.Core.type__int.html'>int</a>) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__unit.html'>unit</a></pre></td><td><summary>
|
|
Sort the elements of an array by mutating the array in-place, using the given comparison function as the order
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val sortWith : ('T -> 'T -> <a href='Microsoft.FSharp.Core.type__int.html'>int</a>) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Sort the elements of an array, using the given comparison function as the order, returning a new array
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>[<<a href='Microsoft.FSharp.Core.type_OCamlCompatibilityAttribute.html'>OCamlCompatibilityAttribute</a>
|
|
("This F# library function has been renamed. Use 'unzip' instead")>]
|
|
val split : ('T1 * 'T2) <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T1 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> * 'T2 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td></td></tr>
|
|
<tr valign="top"><td><pre>val sub : 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__int.html'>int</a> -> <a href='Microsoft.FSharp.Core.type__int.html'>int</a> -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Build a new array that contains the given subrange specified by
|
|
starting index and length.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val sum : overloaded</pre></td><td><summary>
|
|
Return the sum of the elements in the array
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val sumBy : overloaded</pre></td><td><summary>
|
|
Return the sum of the results generated by applying the function to each element of the array.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val to_list : 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T <a href='Microsoft.FSharp.Collections.type__list-1.html'>list</a></pre></td><td><summary>
|
|
Build a list from the given array
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val to_seq : 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Collections.type__seq-1.html'>seq</a><'T></pre></td><td><summary>
|
|
View the given array as a sequence
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val tryFind : ('T -> <a href='Microsoft.FSharp.Core.type__bool.html'>bool</a>) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T <a href='Microsoft.FSharp.Core.type__option-1.html'>option</a></pre></td><td><summary>
|
|
Return the first element for which the given function returns <tt>true</tt>.
|
|
Return <tt>None</tt> if no such element exists.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val tryFindIndex : ('T -> <a href='Microsoft.FSharp.Core.type__bool.html'>bool</a>) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> <a href='Microsoft.FSharp.Core.type__int.html'>int</a> <a href='Microsoft.FSharp.Core.type__option-1.html'>option</a></pre></td><td><summary>
|
|
Return the index of the first element in the array
|
|
that satisfies the given predicate.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val tryPick : ('T -> 'U <a href='Microsoft.FSharp.Core.type__option-1.html'>option</a>) -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'U <a href='Microsoft.FSharp.Core.type__option-1.html'>option</a></pre></td><td><summary>
|
|
Apply the given function to successive elements, returning the first
|
|
result where function returns <tt>Some(x)</tt> for some <tt>x</tt>. If the function
|
|
never returns <tt>Some(x)</tt> then <tt>None</tt> is returned.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val unzip : ('T1 * 'T2) <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T1 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> * 'T2 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Split an array of pairs into two arrays
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val unzip3 : ('T1 * 'T2 * 'T3) <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T1 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> * 'T2 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> * 'T3 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Split an array of triples into three arrays
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val zeroCreate : <a href='Microsoft.FSharp.Core.type__int.html'>int</a> -> 'T <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Create an array where the entries are initially the default value Unchecked.defaultof<'T>.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val zip : 'T1 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T2 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> ('T1 * 'T2) <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Combine the two arrays into an array of pairs. The two arrays must have equal lengths, otherwise an <tt>ArgumentException</tt> is
|
|
raised.
|
|
</summary></td></tr>
|
|
<tr valign="top"><td><pre>val zip3 : 'T1 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T2 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> 'T3 <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a> -> ('T1 * 'T2 * 'T3) <a href='Microsoft.FSharp.Core.type__array-1.html'>array</a></pre></td><td><summary>
|
|
Combine three arrays into an array of pairs. The three arrays must have equal lengths, otherwise an <tt>ArgumentException</tt> is
|
|
raised.
|
|
</summary></td></tr>
|
|
|
|
</table>
|
|
</dd>
|
|
</td></tr>
|
|
<tr valign='top'><td>
|
|
<dt><h3>See Also</h3></dt><dd>
|
|
<a href="Microsoft.FSharp.Collections.html">Microsoft.FSharp.Collections</a> </dd>
|
|
</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<br /> <br/><p><i>Documentation for assembly FSharp.Core, version 1.9.6.16, generated using <a href='http://research.microsoft.com/fsharp/'>F# Programming Language</a> version 1.9.6.16</i></p>
|
|
</BODY></HTML>
|
|
|