std::ceil
Template:ddcl list begin <tr class="t-dsc-header">
<td><cmath>
<td></td> <td></td> </tr> <tr class="t-dcl ">
<td class="t-dcl-nopad"><td class="t-dcl-nopad"> </td> <td class="t-dcl-nopad"> </td> </tr> <tr class="t-dcl ">
<td class="t-dcl-nopad"><td class="t-dcl-nopad"> </td> <td class="t-dcl-nopad"> </td> </tr> <tr class="t-dcl ">
<td class="t-dcl-nopad"><td class="t-dcl-nopad"> </td> <td class="t-dcl-nopad"> </td> </tr> <tr class="t-dcl ">
<td ><td class="t-dcl-nopad"> </td> <td > (since C++11) </td> </tr> Template:ddcl list end
Computes nearest integer not less than arg
.
Contents |
Parameters
arg | - | floating point value |
Return value
Nearest integer not less than arg
Notes
If the argument is infinity (positive or negative) or zero (positive or negative), the return value is the same as the argument.
The largest representable floating-point values are exact integers in all standard floating-point formats, so this function never overflows.
This function may, but is not required to, raise FE_INEXACT floating-point exceptions for non-integer arguments.
Example
Output:
12.000000 13.000000 13.000000 13.000000 13.000000