Namespaces
Variants
Views
Actions

std::remainder

From cppreference.com
< cpp‎ | numeric‎ | math
Revision as of 15:35, 17 January 2012 by Cubbi (Talk | contribs)

Template:cpp/numeric/math/sidebar Template:ddcl list begin <tr class="t-dsc-header">

<td>
Defined in header <cmath>
</td>

<td></td> <td></td> </tr> <tr class="t-dcl ">

<td >
float       remainder( float x, float y );
</td>

<td > (1) </td> <td > (since C++11) </td> </tr> <tr class="t-dcl ">

<td >
double      remainder( double x, double y );
</td>

<td > (2) </td> <td > (since C++11) </td> </tr> <tr class="t-dcl ">

<td >
long double remainder( long double x, long double y );
</td>

<td > (3) </td> <td > (since C++11) </td> </tr> <tr class="t-dcl ">

<td >
Promoted    remainder( Arithmetic x, Arithmetic y );
</td>

<td > (4) </td> <td > (since C++11) </td> </tr> Template:ddcl list end

Computes the remainder of the floating point division operation Template:cpp. In difference to fmod, the return type will be negative if Template:cpp.

4) If any argument has integral type, it is cast to Template:cpp. If any other argument is Template:cpp, then the return type is Template:cpp, otherwise it is Template:cpp

Parameters

x, y - floating point values

Return value

remainder of dividing arguments

See also

Template:cpp/numeric/math/dcl list fmodTemplate:cpp/numeric/math/dcl list div