[Tutor] random numbers
Jennifer Cianciolo
jciancio@indiana.edu
Wed May 28 12:41:47 2003
Hi,
I'm having trouble generating random numbers.
if I do
import random
random.random()
I get
TypeError: 'module' object is not callable
and what I would really like to do is get random integers, but I can't
do that either.
if I put in
randrange(1, 10)
I get
NameError: name 'randrange' is not defined
but I found that in FAQ
http://www.python.org/cgi-bin/faqw.py?querytype=anykeywords&casefold=y
es&req=search&query=random
one more thing - what does it mean that random numbers generated by
python are 'psuedo' random? any way to make them not psuedorandom?
thanks in advance
Jen