Namespaces
Variants
Views
Actions

nextafter, nexttoward

From cppreference.com
< c | numeric | math
Revision as of 07:07, 20 April 2012 by P12 (Talk | contribs)

Template:c/numeric/math/sidebar

Defined in header <math.h>
float       nextafterf( float from, float to );
(since C99)
double      nextafter( double from, double to );
(since C99)
long double nextafterl( long double from, long double to );
(since C99)
float       nexttowardf( float from, long double to );
(since C99)
double      nexttoward( double from, long double to );
(since C99)
long double nexttowardl( long double from, long double to );
(since C99)

Returns the next representable value of from in the direction of to. If from equals to to, to is returned.

Contents

Parameters

from, to - floating point values

Return value

The next representable value of from in the direction of to.

Example

See also

C++ documentation for nextafter