14
14
The :mod: `fractions ` module provides support for rational number arithmetic.
15
15
16
16
17
- A Fraction instance can be constructed from a pair of integers , from
18
- another rational number, or from a string.
17
+ A Fraction instance can be constructed from a pair of rational numbers , from
18
+ a single number, or from a string.
19
19
20
20
.. index :: single: as_integer_ratio()
21
21
@@ -25,8 +25,8 @@ another rational number, or from a string.
25
25
26
26
The first version requires that *numerator * and *denominator * are instances
27
27
of :class: `numbers.Rational ` and returns a new :class: `Fraction ` instance
28
- with value ``numerator/denominator ``. If * denominator * is `` 0 ``, it
29
- raises a :exc: `ZeroDivisionError `.
28
+ with a value equal to ``numerator/denominator ``.
29
+ If * denominator * is zero, it raises a :exc: `ZeroDivisionError `.
30
30
31
31
The second version requires that *number * is an instance of
32
32
:class: `numbers.Rational ` or has the :meth: `!as_integer_ratio ` method
@@ -125,7 +125,8 @@ another rational number, or from a string.
125
125
126
126
.. attribute :: denominator
127
127
128
- Denominator of the Fraction in lowest term.
128
+ Denominator of the Fraction in lowest terms.
129
+ Guaranteed to be positive.
129
130
130
131
131
132
.. method :: as_integer_ratio()
0 commit comments