C Tutorial/math.h/nan

Материал из C\C++ эксперт
Версия от 13:32, 25 мая 2010; Admin (обсуждение | вклад) (1 версия: Импорт контента...)
(разн.) ← Предыдущая | Текущая версия (разн.) | Следующая → (разн.)
Перейти к: навигация, поиск

nan

Item Value Header file math.h Declaratin float nanf(const char *content);double nan(const char *content);long double nanl(const char *content); Return returns a value that is not a number and that contains the string pointed to by content.


<source lang="cpp">#include <math.h>

 #include <stdio.h>
 int main(void)
 {
    double f;
    f = nan("2.0");
   
    printf("%f " , f);
 }</source>