Python

Cam Treschuk
Cam Treschuk
7,212 Points

Random module not working

In Workspaces, I imported the random module in a file. But when I try to run it, it gives me an error message. The error looks something like this:

File "/usr/local/lib/python3.6/random.py", line 42, in <module>
from math import log as _log, exp as _exp, pi as _pi, e as _e, ceil as _ceil
ImportError: cannot import name 'log'

1 Answer

KRIS NIKOLAISEN
PRO
KRIS NIKOLAISEN
Pro Student 51,836 Points

Do you have a file named math.py in your workspace?

Cam Treschuk
Cam Treschuk
7,212 Points

Yeah I did, thanks.