isnan function

Syntax

  • bool isnan(value)
  • bool[] isnan(values)

Parameters

  1. valuefloat
  2. valuesfloat[]

Returns

True if value is not a number, false otherwise.

For an array values a new array is returned containing the result of each element.

Related

Examples

isnan(1)
# result = false
isnan(ln(-1))
# result = true
isnan(float("a"))
# result = true
isnan([1, ln(-1)])
# result = [false, true]

In this topic