isnormal() in C++

isnormal(): This function is available in the file cmath. This function returns whether a given number (x) is a normal value, (i.e) it is neither infinity, NaN,zero(0).

Parameters: One parameter is required for this function.

x: The floating-point value.

Syntax:

isnormal(x)

For Example:

isnormal(10) => It return true.

Approach

C++

#include <bits/stdc++.h>
using namespace std;

int main()
{
    double x = 10;

    cout << isnormal(x<< "\n";

    return 0;
}


No comments:

Post a Comment