Is 0 divided by infinity guaranteed to be 0?

我与影子孤独终老i 提交于 2019-12-06 03:19:15

Mathematically, 0/0 is indeterminate, and 0/anything_else is zero. IEEE-754 works the same way.

So 0/infinity will yield a zero. 0/0 will yield a NaN.

Note: not all C++ implementations support IEEE floating point, and some that do so don't completely meet IEEE specifications, so this is not necessarily a C++ question.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!