Skip to content

Commit 3194384

Browse files
Apply suggestions from code review
Co-authored-by: Sergey B Kirpichev <skirpichev@gmail.com>
1 parent 7b327ec commit 3194384

File tree

1 file changed

+5
-8
lines changed

1 file changed

+5
-8
lines changed

Doc/library/intmath.rst

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
1-
:mod:`intmath` --- Mathematical functions for integer numbers
1+
:mod:`intmath` --- integer-specific mathematics functions
22
=============================================================
33

44
.. module:: intmath
5-
:synopsis: Mathematical functions for integer numbers.
5+
:synopsis: Integer-specific mathematics functions.
66

77
.. versionadded:: next
88

99
--------------
1010

11-
This module provides access to the mathematical functions for integer arguments.
11+
This module provides access to the mathematical functions defined for integer arguments.
1212
These functions accept integers and objects that implement the
1313
:meth:`~object.__index__` method which is used to convert the object to an integer
1414
number. They cannot be used with floating-point numbers or complex
1515
numbers.
1616

1717
The following functions are provided by this module. All return values are
18-
integers.
18+
computed exactly and are integers.
1919

2020

2121
.. function:: comb(n, k)
@@ -30,14 +30,12 @@ integers.
3030
to the coefficient of k-th term in polynomial expansion of
3131
``(1 + x)ⁿ``.
3232

33-
Raises :exc:`TypeError` if either of the arguments are not integers.
3433
Raises :exc:`ValueError` if either of the arguments are negative.
3534

3635

3736
.. function:: factorial(n)
3837

39-
Return *n* factorial as an integer. Raises :exc:`ValueError` if *n* is not integral or
40-
is negative.
38+
Return factorial of the nonnegative integer *n*.
4139

4240

4341
.. function:: gcd(a, b)
@@ -81,7 +79,6 @@ integers.
8179
If *k* is not specified or is ``None``, then *k* defaults to *n*
8280
and the function returns ``n!``.
8381

84-
Raises :exc:`TypeError` if either of the arguments are not integers.
8582
Raises :exc:`ValueError` if either of the arguments are negative.
8683

8784

0 commit comments

Comments
 (0)