One, download the installation package from the link http://www.python.org/downloads/, note the difference between 32-bit and 64-bit installation package.
https://www.python.org/downloads/windows/such as,
Visible, there are 3 versions in 64-bit:
Web-based Installer is required to complete the installation via networking
Executable installer is an executable (*.exe) way to install
embeddable zip file embedded version, can be integrated into other applications. Https://docs.python.org/3.5/using/windows.html#embedded-distribution
Above 3 ways, if there is network, choose web-based;
I downloaded the 64-bit 3.5.1, then the installation, the default installation to directory C:\Python35, and then add this path to the computer system variable path.
From cmd, enter Python to verify that the installation was successful. If you see, the installation was successful:
In fact, once this step is complete, Python is ready to install. The rest is the IDE that was developed. Next, complete two HelloWorld. Create a new directory on the F-disk Learnpython, and then create a new txt document suffix to. py, the file name is test.py, note that it is not test.py.txt. The icon changes. Right-click to select: Edit with IDLE,
This is a Python installer with its own editor, which enters the following content:
Import sys Reload (SYS) sys.setdefaultencoding ('UTF8') Print ("HelloWorld")
When you save it, you will have the option to encode the cp569, regardless of the default. After entering the Learnpython directory of the F-disk in cmd, enter the command Python test.py to see the following running results:
Baidu made a mistake, said the Python language in the version of the differences caused.
Back to the python2.7 version: https://www.python.org/downloads/release/python-2711/
Set PATH, ditto
Results:
The running result of the above example:
Second, as you will not use VIM to write C code, to the next IDE, yes, then use Eclipse+pydev to build a python development environment.
In Eclipse's help--install new software, click Add Name to enter Pydev, link address input: Http://pydev.org/updates then select Pydev, the other can not be selected. Can be downloaded, and will confirm whether you agree or something. After the installation is complete, restart Eclipse takes effect.
Third, configure the path of the Python.exe in Eclipse.
After opening eclipse, click Window--preference--pydev-------Interpreters (interpreter)---Python interprete-----Click New, Then navigate to the installation path of the Python.exe. For example, this will be configured as well. New workspace python.
Iv. Let Python support Chinese
To be honest, in idle though set as follows:
But still print Chinese on the hanging. Refer to link 2, which points out that there are two places for eclipse to be utf8. It is completely unnecessary, because the default GBK encoding for eclipse itself is very good for Chinese support, just add #coding=utf-8 at the beginning of test.py and OK. You can print Chinese in the following statement:
#import sysreload (SYS)print" Hello, world!" "
If not:
#
Results:
File "D:\work\workspace\LearnPython\com\dxz\Hello.py", line 4
Syntaxerror:non-ascii character ' \xe4 ' in file D:\work\workspace\LearnPython\com\dxz\Hello.py on line 4, but no encoding Declared; See http://python.org/dev/peps/pep-0263/for details
Python Environment setup