Skip to content

Commit 53e8c26

Browse files
Apply suggestions from code review
Co-authored-by: Adam Turner <[email protected]>
1 parent a8b6ca2 commit 53e8c26

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

Lib/numbers.py

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -290,10 +290,10 @@ def conjugate(self):
290290

291291

292292
class Rational(Real):
293-
"""To Real, adds numerator and denominator properties.
293+
"""To Real, Rational adds numerator and denominator properties.
294294
295-
The numerator and denominator values should be in lowest terms with
296-
denominator positive.
295+
The numerator and denominator values should be in lowest terms,
296+
with a positive denominator.
297297
"""
298298

299299
__slots__ = ()
@@ -307,7 +307,10 @@ def numerator(self):
307307
@property
308308
@abstractmethod
309309
def denominator(self):
310-
"""The positive denominator of a rational number in lowest terms."""
310+
"""The denominator of a rational number in lowest terms.
311+
312+
This denominator should be positive.
313+
"""
311314
raise NotImplementedError
312315

313316
# Concrete implementation of Real's conversion to float.

0 commit comments

Comments
 (0)