#include <lcmath.h> double fmax(double s, double r);
fmax
finds the maximum of two double values, s
and r
.
fmax
returns a double value that represents the maximum of the two
arguments.
fmax
is a built-in function.
#include <lcmath.h> #include <stdio.h> main() { double num1, num2; /* numbers to be compared */ double result; /* holds the larger of num1 and num2 */ puts("Enter num1 & num2 : "); scanf("%lf %lf", &num1, &num2); result = fmax(num1, num2); printf("The larger number is %fn", result); }
fmin
, max
Copyright (c) 1998 SAS Institute Inc. Cary, NC, USA. All rights reserved.