SyntaxFix
Write A Post
Hire A Developer
Questions
Another method if you're stuck on <2.6, you don't have numpy, and you don't have IEEE 754 support:
def isNaN(x): return str(x) == str(1e400*0)