mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
Issue #23185: add math.inf and math.nan constants.
This commit is contained in:
parent
845b14cc8e
commit
a5d0c7c2fd
5 changed files with 69 additions and 1 deletions
|
@ -383,6 +383,22 @@ Constants
|
|||
The mathematical constant e = 2.718281..., to available precision.
|
||||
|
||||
|
||||
.. data:: inf
|
||||
|
||||
A floating-point positive infinity. (For negative infinity, use
|
||||
``-math.inf``.) Equivalent to the output of ``float('inf')``.
|
||||
|
||||
.. versionadded:: 3.5
|
||||
|
||||
|
||||
.. data:: nan
|
||||
|
||||
A floating-point "not a number" (NaN) value. Equivalent to the output of
|
||||
``float('nan')``.
|
||||
|
||||
.. versionadded:: 3.5
|
||||
|
||||
|
||||
.. impl-detail::
|
||||
|
||||
The :mod:`math` module consists mostly of thin wrappers around the platform C
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue