Calculate the fraction and integer parts of a floating point number.
double modf (double x, double * ptr_int);
Required Header |
<math.h> |
Return Value
This function returns the fraction part of the floating point number.
Parameters
x
The number to convert
ptr_int
A pointer to storage location of the integer part