資源描述:
《Python Pocket Reference, 4th Edition (2009)》由會員上傳分享,免費在線閱讀,更多相關(guān)內(nèi)容在學(xué)術(shù)論文-天天文庫。
1、PythonPocketReferenceFOURTHEDITIONPythonPocketReferenceMarkLutzBeijing?Cambridge?Farnham?K?ln?Sebastopol?Taipei?TokyoPythonPocketReference,FourthEditionbyMarkLutzCopyright?2010MarkLutz.Allrightsreserved.PrintedinCanada.PublishedbyO’ReillyMedia,Inc.,1005GravensteinH
2、ighwayNorth,Se-bastopol,CA95472.O’Reillybooksmaybepurchasedforeducational,business,orsalespromo-tionaluse.Onlineeditionsarealsoavailableformosttitles(http://my.safaribooksonline.com).Formoreinformation,contactourcorporate/institutionalsalesdepartment:(800)998-9938o
3、rcorporate@oreilly.com.Editor:JulieSteeleProductionEditor:SumitaMukherjiProofreader:KielVanHornIndexer:JohnBickelhauptCoverDesigner:KarenMontgomeryInteriorDesigner:DavidFutatoPrintingHistory:October1998:FirstEdition.January2002:SecondEdition.February2005:ThirdEditi
4、on.October2009:FourthEdition.NutshellHandbook,theNutshellHandbooklogo,andtheO’ReillylogoareregisteredtrademarksofO’ReillyMedia,Inc.ThePocketReferenceseriesdesignations,PythonPocketReference,theimageofarockpython,andre-latedtradedressaretrademarksofO’ReillyMedia,Inc
5、.Manyofthedesignationsusedbymanufacturersandsellerstodistinguishtheirproductsareclaimedastrademarks.Wherethosedesignationsappearinthisbook,andO’ReillyMedia,Inc.,wasawareofatrademarkclaim,thedesignationshavebeenprintedincapsorinitialcaps.Whileeveryprecautionhasbeent
6、akeninthepreparationofthisbook,thepublisherandauthorassumenoresponsibilityforerrorsoromissions,orfordamagesresultingfromtheuseoftheinformationcontainedherein.ISBN:978-0-596-15808-8[TM]1253806016ContentsPythonPocketReference1Introduction1Conventions2Command-LineOpti
7、ons4PythonOptions4ProgramSpecification6EnvironmentVariables7OperationalVariables7Command-LineOptionVariables8Built-inTypesandOperators8OperatorsandPrecedence8OperatorUsageNotes10OperationsbyCategory11SequenceOperationNotes15SpecificBuilt-inTypes16Numbers16Strings19
8、UnicodeStrings33Lists36Dictionaries41Tuples44Files45vSets49OtherCommonTypes51TypeConversions52StatementsandSyntax53SyntaxRules53NameRules54Specif