Could someone please tell me what I may be doing wrong. I keep getting this message when I run my python code:
import random
foo = [\'a\', \'b\', \'c\', \
Sounds like an import issue. Is there another module in the same directory named random? If so (and if you're on python2, which is obvious from print random_item) then it's importing that instead. Try not to shadow built-in names.
You can test this with the following code:
import random
print random.__file__
The actual random.py module from stdlib lives in path/to/python/lib/random.py. If yours is somewhere else, this will tell you where it is.