python environment installation problem

Learn to check the environment first. Win+r opens the running interface, enter cmd and press Enter, python -V to check the installation.
Incomplete installation: The default security anti-virus software is killed, and the
solution: anti-virus software allows, reinstall or repair.
1. Insufficient installation permissions, usually the Windows home version, the installation can be run as an administrator
2. That is, some Lenovo users have python environment variables locally, so problems occur when we read them and cause problems.
Learn to check the environment first. Win+r open the running interface, enter cmd and press Enter, where python is checked (if not, it is not installed, or cmd is opened too early)
Insert picture description here
as shown in the figure. The second one is the environment that comes with the system, if the first one is the system Environment variables, (the phenomenon is that python -V does not display anything, but where python can be viewed), you need to modify it.
Method 1:
Enter the C:\Users\Lenovo\AppData\Local\Microsoft\WindowsApps\ directory and
Insert picture description here
restart to see this The three files are 0, so delete them. (After other operations, it cannot be deleted)
Method 2, Manually configure environment variables
This computer-properties-advanced system settings-environment variables
Add two items to the path:
the main directory of python installation:
scripts file directory:
Insert picture description here
don't let Just be the first one below.Insert picture description here

Guess you like

Origin blog.csdn.net/weixin_47514459/article/details/112523321