|
valarray::applypublic member function
valarray<T> apply (T func(T)) const; valarray<T> apply (T func(const T&)) const; Apply function Returns a valarray with each of its elements initialized to the result of applying func to its corresponding element in *this.The valarray returned has the same length as *this. Parameters
Return valueA valarray object with the results of applying func to all the elements of *this.Example
Output:
See also
|