Reputation: 103
I am new to coding. I installed anaconda2 and installed python36 as a environment in anaconda2. And I activate python36 in the anaconda prompt. Then, I run the following codes on pycharm to test whether my version is switched to python36.
print('3 / 2 =', 3 / 2)
It returns
3 / 2 = 1
The result supposed to be 1.5. Seems it doesn't work.
Is there any thing wrong with my steps? Can I switch version which runs in IDE by activate py36 in prompt?
Another question is what is the difference between anaconda3 and anaconda2 which activated python3.x? Do I need download anaconda3 and switch interpreter in my IDE sitting?
Upvotes: 0
Views: 107
Reputation: 16109
Activating an environment at the command line has no impact on the environment loaded by PyCharm. This is covered in Is it ok having both anacondas 2.7 and 3.5 installed in the same time. The gist is, you can choose the environment in PyCharm in the Project Interpreters section of the Settings/Preferences dialog box. See Conda Support Creating Conda Environments for more details.
Upvotes: 1