Python Little Understanding

Source: Internet
Author: User
A comparison of programming languages
Shell (LINUX), PHP (mostly Web page), Java and Python (common language)
Two ways to learn Python
1. Learn Grammar First
2. Then learn the module (most of the modules are written well, we just need to call it)
Output and input of three Python
1.print (Input)
The role of 1.1 + is to connect strings
1.2 Strings can be multiplied
2. Output
Raw_input (' hint message ') #可以和SHELL中的read-P ' hint info: ' Variable mutual understanding
Four operators
Standard operators: +,-, *,/,//(divisible)
Comparison operators: >=,>,<=,< = =,! = <> (also not equal)
Logical operators: And not OR
Five Python variables
Digital
String (must have quotation marks)
List (a variable can store multiple values) can be modified: [] example:a=[' A ', 1, ' B '] a[0]=33 (Modify) A.append (22) (ADD)
Tuples (multiple values can be stored in a variable) cannot be modified: ()
Dictionary (a variable can store multiple values) can be modified: {} a={' name ': ' Tom '} a[' name ']= ' CK ' (modified) a[' QQ ']=123456 (ADD)

Python Little Understanding

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.