diff options
author | Fred Drake <fdrake@acm.org> | 1998-09-10 18:42:55 (GMT) |
---|---|---|
committer | Fred Drake <fdrake@acm.org> | 1998-09-10 18:42:55 (GMT) |
commit | 9b134bf716eecf5afa11259fdc720a26bcce15f0 (patch) | |
tree | 7189118ddedf8f0dccc38241ddab8e5a22076e0c /Doc/lib/libmpz.tex | |
parent | 7a2f0668e45c7bb096bdf0990510410d20daed72 (diff) | |
download | cpython-9b134bf716eecf5afa11259fdc720a26bcce15f0.zip cpython-9b134bf716eecf5afa11259fdc720a26bcce15f0.tar.gz cpython-9b134bf716eecf5afa11259fdc720a26bcce15f0.tar.bz2 |
Added comment about support for rational numbers, and pointer to
Demos/classes/Rat.py.
Diffstat (limited to 'Doc/lib/libmpz.tex')
-rw-r--r-- | Doc/lib/libmpz.tex | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/Doc/lib/libmpz.tex b/Doc/lib/libmpz.tex index c761ea1..eb5dea8 100644 --- a/Doc/lib/libmpz.tex +++ b/Doc/lib/libmpz.tex @@ -19,8 +19,13 @@ arithmetic routines. Only the interfaces to the \emph{integer} (\function{mpz_*()}) routines are provided. If not stated otherwise, the description in the GNU MP documentation can be applied. +Support for rational numbers\index{rational numbers} can be +implemented in Python. For an example, see the \module{Rat}% +\withsubitem{(demo module)}{\ttindex{Rat}} module, provided as +\file{Demos/classes/Rat.py} in the Python source distribution. + In general, \dfn{mpz}-numbers can be used just like other standard -Python numbers, e.g.\ you can use the built-in operators like \code{+}, +Python numbers, e.g., you can use the built-in operators like \code{+}, \code{*}, etc., as well as the standard built-in functions like \function{abs()}, \function{int()}, \ldots, \function{divmod()}, \function{pow()}. \strong{Please note:} the \emph{bitwise-xor} |