Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit f9793a3

Browse files
committed
Merged revisions 78314 via svnmerge from
svn+ssh://[email protected]/python/branches/py3k ................ r78314 | mark.dickinson | 2010-02-22 15:41:48 +0000 (Mon, 22 Feb 2010) | 9 lines Merged revisions 78312 via svnmerge from svn+ssh://[email protected]/python/trunk ........ r78312 | mark.dickinson | 2010-02-22 15:40:28 +0000 (Mon, 22 Feb 2010) | 1 line Clarify description of three-argument pow for Decimal types: the exponent of the result is always 0. ........ ................
1 parent 19219b4 commit f9793a3

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

Doc/library/decimal.rst

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1215,9 +1215,12 @@ In addition to the three supplied contexts, new contexts can be created with the
12151215
- at least one of ``x`` or ``y`` must be nonzero
12161216
- ``modulo`` must be nonzero and have at most 'precision' digits
12171217

1218-
The result of ``Context.power(x, y, modulo)`` is identical to the result
1219-
that would be obtained by computing ``(x**y) % modulo`` with unbounded
1220-
precision, but is computed more efficiently. It is always exact.
1218+
The value resulting from ``Context.power(x, y, modulo)`` is
1219+
equal to the value that would be obtained by computing ``(x**y)
1220+
% modulo`` with unbounded precision, but is computed more
1221+
efficiently. The exponent of the result is zero, regardless of
1222+
the exponents of ``x``, ``y`` and ``modulo``. The result is
1223+
always exact.
12211224

12221225

12231226
.. method:: quantize(x, y)

0 commit comments

Comments
 (0)