Math.isnan() determines whether float is NaN or not.
import math
x=float('nan')
math.isnan(x)
It checks whether float is NaN or not as same as math.isnan().
import numpy
x=float('nan')
numpy.isnan(x)
According to IEEE standard
, NaN value
is always false
when comparing NaN value
.
Use this to define a function.
def isNaN(num):
return num != num
x=float('nan')
isNaN(x)
593 Uncaught (inpromise) Error on Electron: An object could not be cloned
573 PHP ssh2_scp_send fails to send files as intended
866 When building Fast API+Uvicorn environment with PyInstaller, console=False results in an error
564 rails db:create error: Could not find mysql2-0.5.4 in any of the sources
© 2024 OneMinuteCode. All rights reserved.