简体   繁体   English

VS代码没有运行python

[英]VS code is not running python

Visual Studio code is not an IDE, it is a code editor, which means you cannot run nor debug code naturally, for that you would need to run it on the windows terminal, or install extra packages and dependencies. Visual Studio Code 不是一个 IDE,它是一个代码编辑器,这意味着您不能自然地运行或调试代码,因为您需要在 Windows 终端上运行它,或者安装额外的包和依赖项。 If youre new and just want to learn Python, i suggest starting with a python IDE like the standard one provided or something more advanced like Pycharm, and if you want to program on VsCode and in multiple languages, search some tutorials about how to compile and run code on the windows terminal.如果你是新手,只是想学习 Python,我建议从 python IDE 开始,比如提供的标准 IDE 或者更高级的东西,比如 Pycharm,如果你想在 VsCode 上和使用多种语言编程,搜索一些关于如何编译和编译的教程在 Windows 终端上运行代码。

Provide more details about how you installed python from Microsoft Store, from anaconda or via its official page https://www.python.org/downloads/ .提供有关如何从 Microsoft Store、anaconda 或通过其官方页面https://www.python.org/downloads/安装 python 的更多详细信息。 Try running尝试跑步

python --version

or要么

python3 --version

If so you can run a python file from terminal.如果是这样,您可以从终端运行 python 文件。 Assuming my file is called test.py假设我的文件名为test.py

python test.py

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

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