is_nan() function in PHP


The is_nan() function checks for ‘not a number’ value. It Returns TRUE if num is 'not a number', else FALSE is Returned.

Syntax

is_nan(num)

Parameters

  • num − The value to check

Return

The is_nan() function Returns TRUE if num is 'not a number', else FALSE is Returned.

Example

<?php
   echo is_nan(10)
?>

Let us see another example −

Example

<?php
   echo is_nan(acos(1));
?>

karthikeya Boyini
karthikeya Boyini

I love programming (: That's all I know

Updated on: 26-Jun-2020

35 Views

Kickstart Your Career

Get certified by completing the course

Get Started
Advertisements