best way to learn python for non programmer

Want to know best way to learn python for non programmer? we have a huge selection of best way to learn python for non programmer information on alibabacloud.com

Stupid way to learn python (i)

Environment: notepad++,python2.7.13Compile: Write the. py file first, and then run the script with the Python command in the terminal (the runtime terminal directory to be located in the running. py file directory)Exercise One:In the Python2 version, the double quotation mark "" and the single quotation mark "can be used for output without parentheses, and the statement ends without a semicolon;When you want to output quotes in a sentence, you can use

Stupid way to learn Python (11-20)

print" We have it girls with%d. The number of "% nv_countprint" IT staff: >>> Nan_nad_nv (60,20) Results The number of IT staff is: we have 60 of it boys. We have 20 of it girls.19. Functions and variablesdef cheese_and_crackers (Cheese_count, boxes_of_crackers): print "You had%d cheeses!"% cheese_count print "you h Ave%d boxes of crackers! "% boxes_of_crackerscheese_and_crackers (20, 30) results you have a total of cheeses! You have a boxes of Crackers!amount_of_cheese = Amount_of_crackers = C

Lpthw stupid way to learn Python chapter 20

This section describes the integrated operation of functions and files.were carried out separately. 1, read out all the contents of the file, 2, reset the file to the beginning of the file. 3, print a line.I made a small improvement in this section, set up a global variable, record which line should be entered at the moment, and if so, I'll add one to the number.The code section is as follows:#!/usr/bin/env python#-*-coding:utf-8-*- fromSysImportArgvs

Stupid way to learn Python (1-10)

the same, for example, to deal with an int type Object%r will be more "on the side of the string."String (srring) and textW = "This is the left side of ..." E = "a string with a right side." Print W + ethis is the left side of...a string with a right Side.print "." * 10 .....Printdays= "Montuewedthufrisatsun" months= "Jan\nfeb \nmar\napr\nmay\njun\njul\naug "print" herearethedays: ",days print "herearethemonths:",monthsprint "" "There ' s Somethinggoingonhere.withthethreedouble-quotes.we ' Llbe

Total Pages: 5 1 2 3 4 5 Go to: Go

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.