Python first lesson, initial contact.

Source: Internet
Author: User

Introduction to Python:

is an object-oriented, interpreted computer programming language, invented by Guido van Rossum in 1989. Python provides us with a very well-established codebase, covering a wide range of content such as networks, files, GUIs, databases, text, and more.

Python is suitable for developing content:

Web applications, including Web sites, back-office services, many of the daily needs of small tools, including the system administrator needs the script task, in addition to the other language development programs to be packaged again, easy to use.

Python version:

1.CPython

This interpreter was developed in C language, so called CPython. Running at the command line python is to start the CPython interpreter.

2.PyPy

PyPy is another Python interpreter whose goal is to perform speed. Can significantly improve the execution speed of Python code.

3.Jython

Jython is a Python interpreter running on the Java platform that compiles python code directly to Java bytecode execution.

4.IronPython

Over IronPython is a Python interpreter running on the Microsoft. NET platform that compiles python code directly into. NET bytecode.

Getting Started with Python:

1. First Python code:

Print ("Hello,wlord")

The first sentence of all languages ~

2. About Annotations:

When the line stares: # is annotated content

Multiline Comment: "" "Annotated Content" ""

Single line comment All the selected code? control+/ 3. Module ImportInPort module Python has a large number of modules, the class library includes three:
    • Python-supplied modules
    • Industry-Open Source modules
    • Modules developed by programmers themselves
4. VariablesThe variable name must be case in English, numeric, and and cannot start with a number   5. Process Control If Loop? If condition 1:?         The condition is set to execute the statement elif Condition 2:? The statement to be executed when the condition is established? Else:? None of the above conditions satisfy the statement to be executed While Loop     ? Loop until the condition is met, the condition has been executed? While condition:? Code block? The abort of the while condition, flag setting, Break,continue

Python first lesson, initial contact.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.