A concise Python tutorial-December 8, 2017

Source: Internet
Author: User

Last night began to see, do not know how to write on Windows, looking for a few hours, finally solved, put some want to write down.

1. backslash \ Can write a logical line in multiple physical rows.

2. Tabs (tab), spaces can be used to indent, but the space applicability is large. You can use a single tab or 2 or 4 spaces, only one, get into the habit, the key is that tabs and spaces can not be mixed

3 compiled language execution efficiency is better than interpreted, because the compiler will automatically optimize the target code according to different platforms during the compilation process, and the feature is 1 compile, n run

4-25.5%2.25=-12*2.25+1.5, remainder is 1.5;25.5%2.25=11*2.25+0.75, remainder is 0.75

5Python interpreter When doing Boolean operation, as long as the calculation results can be determined in advance, it will not be back, directly return the results, called short-circuit calculation

A concise Python tutorial-December 8, 2017

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.