File "ex43.py", line 2, in <module>
from random import randint
ImportError: cannot import name randint
Any suggestions for the randint error? I tried reinstalling python, with no luck.
Check any random.py or random.pyc file(which will override python random) in the current folder where ex43.py resides.If there, delete or rename that files.Also check import by
>>>import random
>>>print(random.__file__)
Check it is importing from packages
math.py and math.pyc as you did for random.py in current directory
import random; print(random.__file__)- what does it print?