FreeBSD Manual Pages
MinMax(3) User Contributed Perl Documentation MinMax(3) NAME Algorithm::MinMax - Finding the minimum and maximum of an array with at most 3n/2 - 2 comparisons. SYNOPSIS use Algorithm::MinMax; @a = ( 3, 2, 5, 4, 8, 9 ); @r = Algorithm::MinMax->minmax( \@a ); # $r[0] = minimum = 2 # $r[1] = maximum = 9 DESCRIPTION The implementation finds the minimum and maximum of a given array with at most 3n/2 - 2 comparisons, where n is the number of elements of the array. RETURN Returns an array where the first entry is the minimum and the second entry the maximum of the given array. If minmax is called with an empty array, minmax will also return an empty array. AUTHOR Daniel Etzold, detzold@gmx.de perl v5.32.0 2003-05-27 MinMax(3)
NAME | SYNOPSIS | DESCRIPTION | RETURN | AUTHOR
Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=Algorithm::MinMax&sektion=3&manpath=FreeBSD+12.2-RELEASE+and+Ports>