Pascal / math / maxvalue
arccos, arccosh, arcosh, arcsin, arcsinh, arctan2, arctanh, arsinh, artanh, ceil, ClearExceptions, cosh, cotan, cycletorad, degtograd, degtorad, DivMod, EnsureRange, floor, Frexp, GetExceptionMask, GetPrecisionMode, GetRoundMode, GetSSECSR, gradtodeg, gradtorad, hypot, ifthen, InRange, intpower, IsInfinite, IsNan, IsZero, ldexp, lnxp1, log10, log2, logn, Max, MaxIntValue, » maxvalue, mean, meanandstddev, Min, MinIntValue, minvalue, momentskewkurtosis, norm, popnstddev, popnvariance, power, radtocycle, radtodeg, radtograd, randg, SameValue, SetExceptionMask, SetPrecisionMode, SetRoundMode, SetSSECSR, Sign, sincos, sinh, stddev, sum, sumofsquares, sumsandsquares, tan, tanh, totalvariance, variance,
Funcion: maxvalue()
Sintaxis:
Descripcion: Regresa el valor mas grande en un arreglo
Ejemplo:
Sintaxis:
function maxvalue( const data: array [] of float ):float; function maxvalue( const d
Descripcion: Regresa el valor mas grande en un arreglo
Ejemplo:
Program Example26; { Program to demonstrate the MaxValue function. } { Make sore integer is 32 bit} {$mode objfpc} Uses math; Type TExFloatArray = Array[1..100] of Float; TExIntArray = Array[1..100] of Integer; Var I : Integer; ExFloatArray : TExFloatArray; ExIntArray : TExIntArray; AFLoatArray : PFLoat; AIntArray : PInteger; begin Randomize; AFloatArray:=@ExFloatArray[1]; AIntArray:=@ExIntArray[1]; for I:=1 to 100 do ExFloatArray[i]:=(Random-Random)*100; for I:=1 to 100 do ExIntArray[i]:=Random(I)-Random(100); Writeln('Max Float : ',MaxValue(ExFloatArray):8:4); Writeln('Max Float (b) : ',MaxValue(AFloatArray,100):8:4); Writeln('Max Integer : ',MaxValue(ExIntArray):8); Writeln('Max Integer (b) : ',MaxValue(AIntArray,100):8); end.
Librerias Pascal
Libreria crt - CRT - Pantalla y teclado del PASCAL de Turbo que maneja la unidadLibreria dos - DOS - Interface Turbo Pascal MS-DOS
Libreria Graph - Unidad para manipular los graficos de la pantalla compatible con TP
Libreria Objects - Objetos basicos compatible con TP
Libreria math - Rutinas adicionales matematicas
Libreria Printer - Provee de acceso a la impresora
Libreria strings - Rutinas para el manejo de cadenas
Libreria BaseUnix - Funcionalidad Basica de Linux
Libreria System - Manejo de Archivos - Funciones para la manipulacion de archivos en Pascal