![](https://secure.gravatar.com/avatar/5615a372d9866f203a22b2c437527bbb.jpg?s=120&d=mm&r=g)
July 6, 2020
12:54 a.m.
On Sun, Jul 05, 2020 at 12:15:27PM -0400, David Mertz wrote:
This is a digression, but does anyone have a nice example IN PYTHON of arriving at a NaN without going through infinity. I think Julia is right and Python is wrong about '0/0', but as things are, that's not an example.
I wouldn't expect one in Python, I think there is an unofficial policy of ensuring that Python builtins and the math library will not return NANs unless passed a NAN, or at least an INF, rather they will raise. Chris' example:
1e1000-1e1000 nan
is just a funny way of writing INF - INF :-) -- Steven