My Python growth path---first day---python basics (1)---December 26, 2015 (haze)

Source: Internet
Author: User

December 26, 2015 is a special day, my Python is the road to take the first step. Met the idea of the Python Great God (Alex), also recognized the new aspirations of the same-minded partners, very happy.

Although I've seen some Python videos and books before, it's a bit of a foundation. But here I'm going to keep the empty cup mentality and start all over again. Well, don't say much, let's Python!!!!

I. Introduction of Python

Python is a programming language written by the famous "Uncle Turtle" Guido van Rossum during Christmas 1989 to send a boring Christmas. Now Python has become actually one of the most popular development languages in China

Uncle Turtle to Python positioning is "elegant", "clear", "simple", so the Python program seems always easy to understand, beginners learn python, not only easy to get started, and in the future, can write those very very complex programs. In general, Python's philosophy is simple and elegant, as much as possible to write easy-to-read code, as far as possible to write less code.

What Python can do:

1, network applications: including Web development (? Django, Tornado, Flask), server-side programs (Twisted, Eventlet), and so on.

2. Scientific operation: NumPy, SciPy, matplotlib, ETS, etc.

3. GUI (graphical interface)

4, System Management tools:?? such as Saltstack, Ansible for it configuration management, OpenStack for virtualization, Bacula for backup, etc.

5. Other programs

Advantages of Python:

1, concise, elegant, simple

2. High development efficiency

3. Advanced language

4. Portability

5. Scalability

6, can embed the sex

The disadvantages of Python:

1, the speed is slow, because Python is an interpreted language, so the implementation efficiency is really not high. But a lot of applications don't need to run so fast, because users don't feel it at all. For example, to develop a download MP3 Web application, c program run time takes 0.001 seconds, and the Python program run time needs 0.1 seconds, 100 times times slower, but because the network is slower, need to wait 1 seconds, you think, users can feel 1.001 seconds and 1.1 seconds difference? This is like the F1 car and the ordinary taxi on the third Ring road in Beijing, the same reason, although the F1 racing theory speed of up to 400 km, but because the third ring road traffic jam speed of only 20 kilometers, so as a passenger, you feel the speed is always 20 kilometers.

2, the code can not be encrypted, but what does it matter, no one will waste too much time to study your rotten code.

3. Threads cannot take advantage of multiple CPUs.

Installation of Python

First, depending on your version of Windows (64-bit or 32-bit), download the Python 3.5 installation package from the official Python website and run

Note: Be sure to tick add Python 3.5 to PATH, so the installer will automatically configure the environment variables for you.

Second, Hello World

Now let's start with our first Python code.

1 #!/usr/bin/env python 2 "3 Created on:2015 December 26 4 @author: Rockets 5 Email: [Email protected] 6 version:1.0 7 Descrip Tion:8 help:9 ' "Print (' Hello world! ')

What do you think? Is it really simple?

Run Python

Console output:

Console execution Python

My Python growth path---first day---python basics (1)---December 26, 2015 (haze)

Related Article

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.