官术网_书友最值得收藏!

Conventions

This book uses a variety of text styles to distinguish between different kinds of information. Here are some examples of these styles, and an explanation of their meaning.

Code words in text, database table names, folder names, filenames, file extensions, pathnames, dummy URLs, user input, and Twitter handles are shown as follows: "We look up the class in the dictionary and store it in a variable named PropertyClass."

A block of code is set as follows:

    def add_property(self):
        property_type = get_valid_input(
                "What type of property? ",
                ("house", "apartment")).lower()
        payment_type = get_valid_input(
                "What payment type? ",
                ("purchase", "rental")).lower()

When we wish to draw your attention to a particular part of a code block, the relevant lines or items are set in bold:

    def add_property(self):
 property_type = get_valid_input(
                "What type of property? ",
                ("house", "apartment")).lower()
 payment_type = get_valid_input(
                "What payment type? ",
                ("purchase", "rental")).lower()

Any command-line input or output is written as follows:

>>> c1 = Contact("John A", "johna@example.net")
>>> c2 = Contact("John B", "johnb@example.net")
>>> c3 = Contact("Jenna C", "jennac@example.net")
>>> [c.name for c in Contact.all_contacts.search('John')]
['John A', 'John B']

New terms and important words are shown in bold. Words that you see on the screen, in menus or dialog boxes for example, appear in the text like this: "It will fail with a not enough arguments error similar to the one we received earlier when we forgot the self argument."

Note

Warnings or important notes appear in a box like this.

Tip

Tips and tricks appear like this.

主站蜘蛛池模板: 上犹县| 镇康县| 白城市| 神农架林区| 南召县| 大安市| 清苑县| 米泉市| 潼关县| 堆龙德庆县| 喀喇| 哈巴河县| 九龙坡区| 洮南市| 邓州市| 长海县| 赞皇县| 石河子市| 普格县| 高安市| 郎溪县| 大荔县| 元谋县| 关岭| 晋城| 太仆寺旗| 靖宇县| 全南县| 黄平县| 德钦县| 扶风县| 泾源县| 云林县| 青铜峡市| 孝感市| 台安县| 错那县| 汉寿县| 滨州市| 双辽市| 博野县|