반응형
fmax, fmaxf, fmaxl
헤더 파일
[언어 자료구조 알고리즘/C11 표준 라이브러리 함수] - math.h
double fmax(double x, double y); 최대값
float fmaxf(float x, float y); 최대값
long double fmaxl(long double x, long double y); 최대값
입력 매개 변수 리스트
x 실수
y 실수
반환 값
x, y 중에 큰 수
사용 예
//C언어 표준 라이브러리 함수 가이드
//double fmax(double x, double y); 최대값
//float fmaxf(float x, float y); 최대값
//long double fmaxl(long double x, long double y); 최대값
#include <math.h>
#include <stdio.h>
int main(void)
{
printf("%f\n", fmax(1.0, 1.1));
printf("%f\n", fmax(1.0, 0.1));
return 0;
}
출력
1.100000
1.000000
사용한 함수
반응형
'언어 자료구조 알고리즘 > C11 표준 라이브러리 함수' 카테고리의 다른 글
| isalnum (0) | 2016.05.10 |
|---|---|
| ctype.h (0) | 2016.05.10 |
| assert.h (0) | 2016.05.10 |
| 실수 판별식 매크로 (0) | 2016.05.10 |
| fmin, fminf, fminl (0) | 2016.05.10 |
| fdim, fdimf, fdiml (0) | 2016.05.10 |
| nexttoward, nexttowardf, nexttowardl (0) | 2016.05.10 |
| nextafter, nextafterf, nextafterl (0) | 2016.05.10 |
| nan, nanf, nanl (0) | 2016.05.10 |
| copysign, copysignf, copysignl (0) | 2016.05.10 |