random.randint() wierdness.

Emile van Sebille emile at fenx.com
Wed Aug 2 19:33:00 EDT 2000


It prints! on RH6.2, win95, win98 with 1.6a2 and 1.52
from the shell, idle and pythonwin.

--

Emile van Sebille
emile at fenx.com
-------------------


"Michael Hudson" <mwh21 at cam.ac.uk> wrote in message
news:m3aeev45ww.fsf at atrus.jesus.cam.ac.uk...
> Steve Juranich <sjuranic at condor.ee.washington.edu> writes:
>
> > Could somebody please explain this?
>
> No, because the output you included can't have been
produced by the
> code you showed (unless you have a monumentally ancient
Python).
>
> > >>> for i in range(20):
> > ...     random.randint(1, 32)
>
> How does this get printed?
>
> > ...     print i
>
> Wrt the below, "why".
>
> > ...
> > 14
> > 0    <---------   I don't get it.  Why?
> [schnipp]
>
> Cheers,
> M.
>
> --
>   I also fondly recall Paris because that's where I
learned to
>   debug Zetalisp while drunk.                          --
Olin Shivers





More information about the Python-list mailing list