简体   繁体   English

anaconda 提示符中的 Python 命令不起作用

[英]Python command in anaconda prompt not working

I have downloaded the Anaconda python 3.7 version on my Windows.我已经在我的 Windows 上下载了 Anaconda python 3.7 版本。 When I am writing the "python" command on anaconda prompt its opening new window of Microsoft soft to install python 3.8.当我在 anaconda 上编写“python”命令时,提示其打开 Microsoft 软件的新 window 以安装 python 3.8。

anaconda python 3.7 is a package management and deployment software. anaconda python 3.7是一款package管理部署软件。 The idea behind it, is that it allows you to create environments where you have access to such packages and is, therefore, able to develop things using python language or any other language.它背后的想法是,它允许您创建可以访问此类包的环境,因此,能够使用 python 语言或任何其他语言进行开发。

I believe that you are willing to develop stuff in python: in the anaconda prompt, you should create an environment, as described https://docs.conda.io/projects/conda/en/latest/user-guide/tasks/manage-environments.html#creating-an-environment-with-commands我相信您愿意在 python 中开发东西:在 anaconda 提示符下,您应该创建一个环境,如https//docs.conda.io/en-guide/tasks/con -environments.html#creating-an-environment-with-commands

$ condo create -n envpy38 python=3.8

after activating the newly created environment, $ condo activate envpy38 , you can specify that you want the python 3.8 package, by using $ condo install -c anaconda python=3.8激活新创建的环境$ condo activate envpy38 ,您可以指定您想要 python 3.8 package,使用$ condo install -c anaconda python=3.8

Then, you will be able to use the python tool to do whatever you are willing to using python 3.8...然后,您将能够使用 python 工具做任何您愿意使用 python 3.8...

If "python" doesn't work, it's usually "py" or "python3".如果“python”不起作用,通常是“py”或“python3”。

Make sure you are in your environment.确保你在你的环境中。 Open anaconda prompt and type conda activate [name of your environment] and then try to run python , pip , python3 or pip3打开 anaconda 提示符并键入 conda conda activate [name of your environment]然后尝试运行pythonpippython3pip3

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM