exists

Checks existence of a value.

Returns 1 if value exists and is not NaN.

Syntax

exists[val]

Parameters

val Value to be checked.
Return Value 1 if val exists and is not NaN, 0 otherwise.

Examples

#<result> = exists[#<val>]
(print,#<result>)

result: 0


#<val> = 99
#<result> = exists[#<val>]
(print,#<result>)

result: 1


#<val> = nan[]
#<result> = exists[#<val>]
(print,#<result>)

result: 0

See also

notexists, nan, def