python运行失败

问题描述 投票:0回答:1

我的 python 有问题。它显示 python 运行失败错误 (https://i.stack.imgur.com/0ZI7z.png)

我尝试在 vscode 中运行简单的 python 程序,它显示错误('python 运行失败')。当我在命令提示符中输入命令(python --version)时,它显示 python 版本,但它抛出终端中出现错误。我尝试在 vscode 中运行我的 c++ 文件,它们工作得很好。我的 python 版本是 python 3.11.4。谁能帮我解决这个问题吗

python powershell terminal command-prompt
1个回答
0
投票

在环境变量中添加

python
(或python解释器)的路径,以在命令行或shell上运行python。

© www.soinside.com 2019 - 2024. All rights reserved.