What is Python? Quickly read this article to get you started with Python quickly

Tomorin
Release: 2018-08-25 14:43:21
Original
1465 people have browsed it

Python This language is considered a relatively young language. This language was born in 1989 and was invented by Guido van Rossum, who is considered the youngest generation born in the 1980s. In just a short period of time, Two years later, in 1991, it was officially released to the public.

This article will introduce to you, PythonWhat is it, how do we get started, and how to learn Python.

What is Python? Quickly read this article to get you started with Python quickly

Everyone who has learned this language knows that Python is not as cumbersome and logically confusing as other languages. It's so simple that you can write Java with just a dozen lines of code. JavaScript and C require dozens or even hundreds of lines of code. It's also very beautiful. Even if you're just a beginner, as long as you have a little bit of knowledge With the basics of programming language logic, you will be able to clearly understand the logical syntax of Python - simple, clear, and straightforward. If you compare her to a human being, she is like a lady from Mississippi, with decent manners but good conversation. But generous.

Python

This language has been warmly welcomed as soon as it came out, and in the years when computer technology has become increasingly mature, it also successfully topped the programming language rankings in 2017. , a language that is jointly certified by programmers around the world. Having said so much, what is

python

? How do we get started?
Python

Although it has a glorious history, it is not a language across all platforms. Before the publication of

Python3.0, we used an editor to write## When #Python comes, we still need to build an environment where Python can run on the computer. It’s like raising a tropical reptile as a pet in China. We must build it for people no matter what. An environment suitable for her survival. The following content is only for Python3.0 and previous versions:

The first line of code about python
is not like other languages In that way, go up to a standard "hello world". As mentioned above, you need to set up an environment:

#!/usr/bin/python
Copy after login
The meaning of the above code is to facilitate our editor in the folder pointed to by the code. Looking down layer by layer, I found the editor interpreter named python
, but there must be a special situation. If a user fails to install the

python

interpreter due to certain reasons, If it is not installed in the /usr/bin folder for some reasons, the python editor cannot be found. To this end, we have another piece of coding:

#!/usr/bin/env python
Copy after login
The env in this line of code means to prevent the user from putting the Python file into the usr/bin file and browsing it as an editor. When the code detects

env

, it will directly ignore the previous /usr/bin, and directly search for the Python file on the computer, and find the file that is suitable for the current editor. interpreter. Then someone will ask, why can’t we use Python after such a big effort? As you said before, this is a version before

Python

3.0. What about versions after 3.0 and Python3.0? The reason is very simple. Although programming language is a concept linked to computers, it itself is a substance that contains the characteristics of "computer" and "language" - like a computer, it can change at any time. As the version is updated, constant updates make it more convenient for programmers, but just like a language, the older and longer it is, the more vocabulary it can contain and the more capable it is. Even today, one year after Python topped the programming rankings, there are still many people using Python2.0, just like fine wine, the longer it goes, the more mellow it becomes.

I mentioned the editor earlier, so what kind of editor is suitable for Python?

In fact, when it comes to editors, we can jokingly say: you can use text documents.
Yes, it is really possible, but we have worked hard to evolve to this point, and we do not want to go back and use the most primitive methods to do this. Here I strongly recommend two editors:



Dreamweaver CS6

http://www.php.cn/xiazai/gongju/469

notepad: http://www.php.cn/xiazai/gongju/92

These two editors are the two most widely used editors currently known. tools, and more importantly, they are quite convenient. Unlike the text documents I ridiculed before, you don’t know whether you are writing right or wrong. You can check and correct errors while writing. Programmers are always fixing and writing bugs. ~
The above is about getting started with Python.

The above is the detailed content of What is Python? Quickly read this article to get you started with Python quickly. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!