hi,

The code iam working on accepts numeric input from the user and stores it into a double variable. The user can enter either floating point numbers or integers. How do i identify if the user has entered a floating point type or an integer type?

I've thought up the following code to figure out if the given number is of floating point type:
Code:
if( floor (doublevar) < doublevar )
    //doublevar is of floating point type
this seems to work fine, is it correct? How do i check if the given number if of integer type?

thanks in advance